You must be logged in to post. Please login or register an account.
You just have to change the code a little bit and install a pip
Open your terminaland type pip install fix_yahoo_finance
then in you code :
#import the pip
import fix_yahoo_finance as yf
yf.pdr_override()
#change this line
df = web.DataReader('TSLA', "yahoo", start, end)
#to
df = web.get_data_yahoo('TSLA', start, end)
I hope it's help
-mystique1011 7 years ago
You must be logged in to post. Please login or register an account.
I wasn't able to get it to work. Is this working for anyone else? Thanks!
-Smitty 7 years ago
Last edited 7 years ago
You must be logged in to post. Please login or register an account.
nevermind, I believe. I have found the answer here. https://pythonprogramming.net/community/650/Prog%20for%20Finance-%20Data%20scraping%20S&P500%20P6/
-Smitty 7 years ago
You must be logged in to post. Please login or register an account.