Python Forum
How to define train set and test set
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to define train set and test set
#3
Yes, I am using sklearn
my definition as below:
X_train,X_test,Y_train,Y_test=train_test_split(x,y,test_size=0.3,random_state=0)
My data size is 1000, and I want to split first 700 as train data and next 300 data as test data,
But using above comment, it splitting randomly,
Reply


Messages In This Thread
How to define train set and test set - by Raj - Mar-02-2018, 02:56 PM
RE: How to define train set and test set - by mpd - Mar-02-2018, 05:38 PM
RE: How to define train set and test set - by Raj - Mar-05-2018, 01:39 PM
RE: How to define train set and test set - by mpd - Mar-05-2018, 02:08 PM
RE: How to define train set and test set - by Raj - Mar-07-2018, 01:15 PM
RE: How to define train set and test set - by mpd - Mar-07-2018, 01:49 PM
RE: How to define train set and test set - by Raj - Mar-08-2018, 01:04 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Why is my train and test accuracy so low? python420 0 2,062 Dec-08-2019, 08:51 PM
Last Post: python420
  Partitioning when splitting data into train and test-dataset Den0st 0 1,988 Dec-07-2019, 08:31 PM
Last Post: Den0st
  Need help; iris-train Karin 2 2,673 Apr-12-2019, 02:16 AM
Last Post: Karin

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020