

Hi guys! Could somebody please help me with this. bh_df is the data set I am working with. As you can see now the data is between approx. 79 and 77. I need to scale it between -1 and 1. Thank you in advance! I wanted to do x_max-x_min thing (advised here https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.MinMaxScaler.html), but my min data point is 0, so I do not think it will do anything useful.
To do so, you need a function that transforms your data so that
Using pandas
Using
sklearn.preprocessing.MinMaxScalerAs as side note, if the data is supposed to be fed to a ML model, you should call
fit()on training andtransform()over test and validation sets.