The common data format in Machine Learning is a CSV file (comma separated values). In this Tutorial I show 4 different ways how you can load the data from such files and then prepare the data. I also show you some best practices on how to deal with the correct data type, missing values, and an optional header. The 4 approaches are:

  • with the csv module
  • with numpy: np.loadtxt() and numpy.genfromtxt()
  • with pandas: pd.read_csv()

Get access to the ML notebooks:
https://www.patreon.com/patrickloeber

The code and all Machine Learning tutorials can be found here:
https://github.com/python-engineer/MLfromscratch

#machine-learning #python #programming #developer

How to Load Machine Learning Data From Files in Python
7.55 GEEK