Sitemap

Scrape Yahoo Finance

3 min readFeb 3, 2022

--

How to Scrape most active stocks in Yahoo Finance without any input.

*************************************

Press enter or click to view image in full size

Coding

The modules are well documented, it shows you how to collect the data, I want to improve it a little bit so that the data will be saved as CSV and you can use it for doing your research as a machine learning engineer. Here is the code that I created.

Without Coding

To make a bot which scrape most active stocks in Yahoo Finance without any input, follow these steps:-

1. To create a new bot, click DK extension and type “yahoo_most_active” and then click “ + New Api”.

2. Now open https://www.studioproper.com/collections/shop-all-products in the browser before training the bot, and click “Record” to train the bot.

Press enter or click to view image in full size

3. Then Reload the page to add the URL to the event. https://finance.yahoo.com/most-active/,

Press enter or click to view image in full size

4. Add static wait to take time for browser to load the page Datakund=>Wait=>Static=>3, to scrape the product name.

Press enter or click to view image in full size

5.Then add scroll to end to add event to get all the stocks after scroll Datakund=>More=>Scroll to end, to scrape the stocks name.

Press enter or click to view image in full size

6. Now right click on the website screen, then click Datakund=>Start Repeat, to add loop for scraping similar items.

7. Now click the keyboard icon to add the outputs such as symbol
stock
price
change
%change
volume
yahoo_link
market_cap
p_e , then click on save and back to recording

Press enter or click to view image in full size

8.Then right click on first stock and then Datakund=>Scrape=>Text=>symbol, to scrape the stock symbol.

Press enter or click to view image in full size

Similarly we can scrape stock - name, price, chane, volume, market_cap, p_e.

Press enter or click to view image in full size

9. Now stop the training(by back), and click “run”.

Press enter or click to view image in full size

10. As there is no input needed just click “Run Google sheet”

11. Now the inputs are scrape automatically, status can be seen in notifications

Press enter or click to view image in full size

12.Results can be seen in extension as well as update in google sheet, in output sheet of spreadsheet.

Press enter or click to view image in full size
Press enter or click to view image in full size

--

--