Created
July 20, 2019 02:47
-
-
Save kperry2215/9a08723c674cd8f83880884a566f0929 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Transform the columns using natural log | |
master_df['Electricity_Price_Transformed']=np.log(master_df['Electricity_Price']) | |
master_df['Nat_Gas_Price_MCF_Transformed']=np.log(master_df['Nat_Gas_Price_MCF']) | |
#Difference the data by 1 month | |
n=1 | |
master_df['Electricity_Price_Transformed_Differenced'] = master_df['Electricity_Price_Transformed'] - master_df['Electricity_Price_Transformed'].shift(n) | |
master_df['Nat_Gas_Price_MCF_Transformed_Differenced'] = master_df['Nat_Gas_Price_MCF_Transformed'] - master_df['Nat_Gas_Price_MCF_Transformed'].shift(n) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment