Changed Unix Timestamp for Time when creating csv

This commit is contained in:
Alberto Soutullo 2024-03-07 11:34:27 +01:00
parent 0fc2fb967e
commit 6c0f119498
No known key found for this signature in database
GPG Key ID: A7CAC0D8343B0387
1 changed files with 3 additions and 3 deletions

View File

@ -96,9 +96,9 @@ class Scrapper:
return df
def _create_pod_df(self, column_name: str, values: List) -> pd.DataFrame:
pod_df = pd.DataFrame(values, columns=['Unix Timestamp', column_name])
pod_df['Unix Timestamp'] = pd.to_datetime(pod_df['Unix Timestamp'], unit='s')
pod_df.set_index('Unix Timestamp', inplace=True)
pod_df = pd.DataFrame(values, columns=['Time', column_name])
pod_df['Time'] = pd.to_datetime(pod_df['Time'], unit='s')
pod_df.set_index('Time', inplace=True)
return pod_df