Python for Finance: getting stock data with pandas datareader

preview_player
Показать описание
Today we explore how to import stock data from yahoo finance with pandas datareader using python. We also explore how to visualise and subsection stock data in pandas dataframe form. Using pandas describe method we are able to quickly derive useful information from specific stocks, and with the .plot method we can graph stock data with both matplotlib and/or plotly extremely easily.

As a high-level programming language, Python is a great tool for financial data analysis, with quick implementation and well documented API data sources, statistical modules and other frameworks related to the financial industry. We will be using Jupyter Lab as an interactive web browser editor for this series due to ease of use, and presenting code in a live notebook is ideal for this tutorial series.

This is the first video of many on the topic of Python for Finance. The series will include general techniques used for financial analysis and act as a introduction for more in depth tutorials that we may explore later (such as time series modelling, building financial dashboards, machine learning ect.).

★ ★ QuantPy GitHub ★ ★

★ ★ Discord Community ★ ★

★ ★ Support our Patreon Community ★ ★
Get access to Jupyter Notebooks that can run in the browser without downloading python.

★ ★ ThetaData API ★ ★
ThetaData's API provides both realtime and historical options data for end-of-day, and intraday trades and quotes. Use coupon 'QPY1' to receive 20% off on your first month.

★ ★ Online Quant Tutorials ★ ★

★ ★ Contact Us ★ ★

Disclaimer: All ideas, opinions, recommendations and/or forecasts, expressed or implied in this content, are for informational and educational purposes only and should not be construed as financial product advice or an inducement or instruction to invest, trade, and/or speculate in the markets. Any action or refraining from action; investments, trades, and/or speculations made in light of the ideas, opinions, and/or forecasts, expressed or implied in this content, are committed at your own risk an consequence, financial or otherwise. As an affiliate of ThetaData, QuantPy Pty Ltd is compensated for any purchases made through the link provided in this description.
Рекомендации по теме
Комментарии
Автор

if you are facing an error: string indices must be integers
I found a solution somewhere
0) pip install yfinance
1) import import yfinance as yf
2) yf.pdr_override()
3) df = pdr.get_data_yahoo(stocks, start, end) and run it

ruhipanchal
Автор

I feel like I learned more useful stuff than in some of my actual uni courses. Just subscribed, looking forward to digging through your archive.

aron
Автор

This tutorial is so well done. Thank you thank you thank you!!

jenniferkirschnickduffy
Автор

Great video, a little bit of suggestion for videos that you should make your live cam smaller in corner and zoom a little on the code that you are typing so people can see it clearly.

pkavenger
Автор

amazing video, this is great stuff please keep it coming. Thank you very much for giving up your time to do this.

nickdechip
Автор

Niccceeee. This is exactly what I have been looking for. Thank you

SD-gwvm
Автор

very well explained tutorial, thanks a lot @QuantPy !!

John-xiim
Автор

Great stuff. Didn't know it's that easy using pandas. Thanks. (Y)

tamoorkhan
Автор

Best video on yahoo finance data fetching

yashsaraswat
Автор

doesn't work
TypeError: string indices must be integers

SM-fbqb
Автор

error: module is not found for pandas_datareader

xiupingli
Автор

good stuff mate, worked like a (py) charm!

ih
Автор

Hi Johnathon,
A few questions:
(1) when will you have the video available idincating how to import all ASX200 stocks,
(2) How do we convert the Jupyter script to just a python script,
(3) What is the maximum numbers of stocks you can request information on via a script

roncarr
Автор

Amazing, thx so much, support as always !

neronjp
Автор

really great stuff, thx.
a sidenote:
please use s higher fontsize to simplify following if watching on a mobile phone... It is not always the Laptop, often it is browsing through sophisticated topics but with mobile phone, getting an idea of what is possible standard fonts on the Display and too small to follow.
Please use a reasonable fontsize... maybe 2 or 3 points higher, there is enough space for it to do so.... thx. :)

yildirimicen
Автор

Thanks for this tutorial.
Juste Data_source="Yahoo" doesn't work (NotImplementedError

nyxnix
Автор

The link to the full code doesn't work

farshadfarzan
Автор

How to resolve the following error?


TypeError: string indices must be integers

code: df = web.get_data_yahoo(stocks, start, end)

aravinthmegnath
Автор

Hello, I just stuck at the beginning, I got a bug with the pandas_datareader

dvtoro
Автор

im on mac and im not really sure how to get jupyter lab working i have pandas and pandas-datareader downloaded in python but it is not working

harrye
visit shbcf.ru