Tag: pandas
-
Python Exercise for Beginners – Implementing One Hot Encoding
In today’s Python exercise we will create a one-hot encoding algorithm to convert categorical data to a numerical format. The reason why we need to do this is that machine learning algorithms only can deal with numbers, not strings. What is One Hot Encoding? One-hot encoding is a way of representing categorical information in binary […]
-
How to create a Panda Dataframe from an HTML table using pandas.read_html
It is possible to use Panda Dataframes to scrape directly an HTML table from a URL. This can be incredibly useful and a quick way to extract useful data, when you are in a hurry. To see how valuable it is, let’s use a concrete example. Imagine that we want to scrape some information about […]
-
Read CSV File using Python pandas.read_csv() and write to CSV file using pandas.write_csv()
Reading a CSV with Python and the panda library, from a file is a very simple, and something that you are likely going to have to do many times during your career as a data scientist. As an example lets read an image dataset I gathered of all the paintings I could find about the […]