Introduction
This article describes how to create a filter for splitting your sample. This feature has multiple use cases, such as splitting the sample for predictive modeling such as regression; for creating a training, validation, and testing sample based on a filter; or for removing a proportion of a sample.
This article explains the required steps to generate each of the below three filter examples.
Requirements
- A Displayr document containing a data set.
Method - creating a training and testing filter
- Go to the Anything menu, and select Filtering > Model Checking > Filters for Train-Test Split.
- When prompted input the percentage of the data set that should be used as the training set. By default, this is set to 70%. Select OK.
- Displayr will create a Train test split variable usable as a filter.
Method - creating a training, validation, and testing filter
-
- Go to the Anything menu, and select Filtering > Model Checking > Filters for Train-Validation-Test Split.
- When prompted input the percentage of the data set that should be used as the training set. By default, this is set to 50%. Select OK.
- In the second prompt, input the percentage of the data set that should be used as the validation set. By default, this is set to 25%. Select OK.
- Displayr will create a Train validate test split variable usable as a filter.
Method - removing a proportion of a sample
- Go to the Anything menu, and select Filtering > Model Checking > Filters for Train-Test Split.
- When prompted input the percentage of the data set that you wish to keep. By default, this is set to 70%. Select OK.
- Displayr will create a Train test split variable usable as a filter.
- To remove the respondents from the data set, select the data set by clicking on it in the Data Sets tree.
- With the data set selected, go to the object inspector > Properties > Delete observations...
- Select the condition and the filter (e.g. Data not matching Filter Training sample filter will be deleted (5%)), and select Delete.
See Also
How to Remove Cases From Raw Data Using a Filter
How to Tag a Variable as a Filter
Comments
0 comments
Article is closed for comments.