I'm trying to organize my pandas data frame like the one we get from yahoo finance data frame of multiple stock symbols with OHLCV. how to achieve that.
i tried.
df = df[['Name','datetime','open','high','low','close','volume']]
df.set_index(['Name', 'datetime'], inplace=True)
df = df.astype(float)
and got the following output.

It depends what need. If need all columns in
MultiIndexin columns:If need processing only one column, e.g.
open: