Get the Detailed code from https://www.worthwebscraping.com/how-...
Once we have scraped data from any website it is important to save it so that we can access it for future use, or do some analysis or clean it. Scraping data and merely displaying on the screen doesn’t make any sense.
When dealing with text data we can save it in multiple ways like in a CSV file, Excel file, Text file, Google Spreadsheet in a Database like MySQL, MongoDB etc. For Images, Videos, Audios and other kind of media we can save it on our local system or in a database.
Saving data to a CSV or Excel file is the most common and most used method for text data as it is easy to do, can be accessed easily and shared. In this tutorial we will see how to save text data to CSV and Excel files.
There are two ways to save data to CSV and Excel
1. Using CSV module
2. Using Pandas Dataframe.
we will be learning both the methods in this tutorial.
Watch our series on Python web scraping step by step on our channel.
#Python #Pythonscraping #scraping