Dear Guru's.
I have downloaded BHAV copy for today and yesterday from NSE and using read_csv read the file
I am trying to calculate the price change and then the price % change for the asset. However I am unable to use the substract function.
Below is the code.
The columns:
T_CLOSE is todays close price
Y_CLOSE is yesterdays close price
# percentage change in price
analysis_df['pct_price_chg']= analysis_df(,['T_CLOSE'] - ['Y_CLOSE'])
I have tried this as well.
# percentage change in price
analysis_df['pct_price_chg']= analysis_df['T_CLOSE'] - analysis_df['Y_CLOSE']
Could you please suggest how to proceed.