i have a data set called "sales" which is a SFrame. there's a column called "sqft_living" and i want to convert it to log value. data type of column is float. but when i try to convert it with log() function it asks a float although its already a float. here are the screenshot of codes and error. could you please help me to find the issue and convert the column to log
a=train_data['sqft_living']
a
result of a
dtype: float
Rows: 17384
[1180.0, 2570.0, 770.0, 1960.0,...]
this shows that "a" is float
then i used below code to transform to log value in to new column called 'log_sqft_living'
train_data['log_sqft_living']= log(a)
but it gives be below error
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-23-6de995ee575f> in <module>()
----> 1 train_data['log_sqft_living']= log(a)
TypeError: a float is required