Date Split:
Now take a column with datestring and now generate columns in dataframe such as day, month, year, hour, minute, second
Method Structure:
.. code-block:: python
def date_split(df, col_name):
''' Your code goes here '''
return dataframe
Parameters:
df : pandas dataframe
- Enter the dataframe directly
col_name: str
- Enter the column name which consist of datetime string
Usage:
.. code-block:: python
>> p = process()
>> p.date_split(pd.DataFrame(), col_name='date')
>> <pandas.dataframe>