I am trying to compute the percent change for each stock in a for loop. I want to find the 1-month return.
why does this not work?
for stock in context stock:
day30_hist=data.history(stock, "price", 90, "1d")
day30_perc_chg=day30_hist[stock].pct_change()[-1]
Thanks