If you plan on investing in stocks, it is definitely a good idea to take a quick look at the individual historical stock prices. The first step would be to download the historical prices- but the stock exchange sites do not allow you to efficiently pull data for all the stock prices listed. Listed below are the main steps to pull day by day stock price data for all the stocks listed in NSE (National Stock Exchange of India) :

Import modules- pandas, numpy, datetime, csv, pandas_datareader Input start and end date between which we want the stock prices Extract all the stock symbols listed on NSE e.g 20MICRONS, RELIANCE, BOSCHLTD Run a for loop to download the stock price data for each of the stock symbols. In the for loop we would be using web.Datareader() function to download data from quandl Clean and append the data and we should have the following analytical dataset :

6. We can use this data to perform all the analysis and visualizations we need

Price Trend for “SUTLEJTEX” STOCK

Please find below the complete code in Python to perform the above steps :