I am using NSEPY API and I would like to list out the stocks which are included in nifty 50 indice.
I am getting history data for the individual stocks but not getting nifty 50 stocks (totally 50 stocks). I want to retrieve it .
import nsepy
from nsepy import get_history
from datetime import date
data = get_history(symbol="IOC", start=date(2017,1,1), end=date(2019,2,15))
data[['Close']].plot()
I want the results for 50 stocks but I am getting results for specific stick which I have given in symbol