From the course: Build Three Real-World Python Applications
Unlock the full course today
Join today to access over 24,400 courses taught by industry experts.
How to pull stock data with the requests package - Python Tutorial
From the course: Build Three Real-World Python Applications
How to pull stock data with the requests package
- [Instructor] Now, we will pull Apple stock data using the request package. This method will use the request package that we imported earlier, along with heavily relying on the Alpha Vantage documentation, so make sure to reference this documentation as needed. We will begin by using the time series monthly function to get the monthly data for our Apple stock. The time series monthly section shows the description of this function and how it gathers the monthly time series data. It also has multiple parameters, with three of them required and one of them being optional. So, you'll see we need to add in the function symbol and API key, but the data type is optional. If we scroll down to look at the Python code provided, we will see it gives us the specific URL to use with our time series monthly function, the stock symbol, IBM, and the variable demo for our API key. I highly suggest to copy and paste these URLs from…
Contents
-
-
-
-
What are APIs?2m 16s
-
(Locked)
Introducing Alpha Vantage API4m 1s
-
(Locked)
How to access Alpha Vantage data3m 7s
-
(Locked)
How to use an API key5m 32s
-
(Locked)
How to pull stock data with the alpha_vantage package: Part 14m 5s
-
(Locked)
How to pull stock data with the alpha_vantage package: Part 22m 1s
-
(Locked)
How to pull stock data with the requests package5m 55s
-
(Locked)
How to put stock data into a DataFrame6m 8s
-
(Locked)
How to use Alpha Vantage functions: Part 14m 5s
-
(Locked)
How to use Alpha Vantage functions: Part 23m 21s
-
(Locked)
How to use Alpha Vantage functions: Part 36m 25s
-
(Locked)
Challenge: Analyze Microsoft stock2m 31s
-
(Locked)
Solution: Analyze Microsoft stock2m 32s
-
-
-