I am trying to shape a array for use with scipy, sklearn etc.. I have a csv file I am importing using pandas like so -
df = pd.read_csv('data.csv')
which gives me this data -
>>print df
Model | Trim | Cost
6 | 102 | 1200
8 | 105 | 1500
15 | 110 | 3000
I would like to shape it to an array like so
array = []
array.append(df)
>>print array
[[6,102,1200],[8,105,1500],[15,110,3000]...]
I have tried append, extend, shape, reshape and still cannot seem to get it right.. What is the correct way to accomplish this?