So I intend to build a predictive model.I have a large data set with 10 features and 1 interval target. One of those features is numeric ranging from 1 to 900. I know that due to some underlying changes in the population, records from about 1 to 250 are underrepresented in my sample, and 251+ are over represented. I approximately know what the distribution of this feature should look like. Is there a way I can easily sample from dataset with replacement so that the distribution of this feature matches percentages I give it?
Thanks.
One way would be to add a strata variable based on whether the value is over/under the given break point. I don't know if EM has a direct sampling tool but Proc surveyselect allows setting a sample rate per strata.
One way would be to add a strata variable based on whether the value is over/under the given break point. I don't know if EM has a direct sampling tool but Proc surveyselect allows setting a sample rate per strata.
I ended up breaking my data into several segments depending and the value of my numeric feature, and used proc surveyselect to sample with replacement form the individual pieces until the overall distribution of my data looked as I expected it to. Thanks!
Hi Jon,
A way to do it directly in EM:
On your Data Partition node, click on the Variables ellipsis (...). On the menu you can specify a Partition Role as Stratification.
e.g.
Home Equity IDS->Partition (change Partition Role of 'Reason' from Default to Stratification)
I hope this helps,
Miguel
Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.
Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.
Use this tutorial as a handy guide to weigh the pros and cons of these commonly used machine learning algorithms.
Find more tutorials on the SAS Users YouTube channel.