importpandas_datareader.dataaspdr #事先安装:pip install pandas-datareader# from pandas_datareader import data as pdrsp500=pdr.DataReader(name='^GSPC',data_source='yahoo',start='1/1/2019',end='4/14/2019')#标普500sp500.info() #apple=web.get_data_yahoo('AAPL')#苹果股票# apple.info() #stock_300481=pdr.get_data_yahoo('300481.sz','1/1/2015','20/8/2015')#创业板股票:300481# stock_300481.info()