dataset = [library alias name].read_csv(‘file.csv’)
x = dataset.iloc[:,:-1].values
y = dataset.iloc[:, -1].values
In the above lines, read_csv and iloc are functions.
[:,:-1] is slicing range of the values.
Blogger, Engineer & Entrepreneur
dataset = [library alias name].read_csv(‘file.csv’)
x = dataset.iloc[:,:-1].values
y = dataset.iloc[:, -1].values
In the above lines, read_csv and iloc are functions.
[:,:-1] is slicing range of the values.
Facebook Comments