2
$\begingroup$

I'm trying to figure out the difference between using the data sampler to get a 70/30 train/test split and directly using the test and score widget to do so via random sampling. My workflow as follows

enter image description here

This is how my test and score widget looks for the case without the data sampler

enter image description here

and this is how my data sampler widget looks

enter image description here

I see very different results in the confusion matrix at the end between the two. Using the data sampler, I get a much better model than without it. However, if I directly try and leverage the train_test_split function with LogisticRegression in scikit-learn with similar hyper params as Orange(e.g. for solver, C, class_weights etc.) My results there are much closer to what I see in Orange without using data sampler.

  • Could someone help me figure out what I'm missing?

  • What is the difference between the two widgets in how I'm using them?

  • Does the 70% in DataSampler not correspond to a train_test_split function in scikit-learn with train_size=0.7?

$\endgroup$
0
$\begingroup$

Figured out the issue, I'd mis-configured the channels between the 'data sampler' and 'test and score' widgets to use only training data for testing. It should in fact be configured this way instead-->

enter image description here

Earlier I had 'Data Sample' from the 'Data Sampler' mapped to both 'Data' and 'Test Data' in the 'Test and Score' widget. 'Remaining Data' is what needs to be mapped to 'Test Data' as that is the 'out of sample' data set for testing.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.