Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

Assigning X and y using .iloc index

X=data.iloc[:,[0,1,2,3,5,6]]#<class 'pandas.core.frame.DataFrame'>
y=data.iloc[:,4]#<class 'pandas.core.series.Series'> as y has only one column it is a series
Source by colab.research.google.com #
 
PREVIOUS NEXT
Tagged: #Assigning #X #index
ADD COMMENT
Topic
Name
1+5 =