Mar-28-2019, 12:42 AM
(Mar-27-2019, 02:21 AM)scidam Wrote:(Mar-26-2019, 03:54 PM)bhuwan Wrote: By doing above concat, does each row of y_test and y_pred align in the same order as in x_test?
The.predict
doesn't change the order of classified cases. Let X_test.shape = (m, n), then
y_test.shape = n
(preserving order is guaranteed bytrain_test_split
in this case); finally,y_pred
is produced by.predict
, this function retains the order of classified items (rows ofX_test
).
Thank you so much, this is what I needed to confirm.