The criteria for keeping an observation is called the inclusion criteria. Inclusion and exclusion criteria are both statements of conditional logic that are based on one or more variables, and one or more values of those variables.Ĭreating a subset that contains only records with a certain value: In this case, your subset will keep the records that meet the criteria you specify. Subsets can be created using either inclusion or exclusion criteria.
#BLOCK VARIABLE SEQUENTIAL TESTING SAS HOW TO#
For instructions on how to drop or keep variables from a dataset, see our Data Step tutorial. Note: A related task is to select a subset of variables (columns) from a dataset. The difference between the two processes is in how the cases are selected. Both processes create new datasets by pulling information out of an existing dataset based on certain criteria. When splitting a dataset, you will have two or more datasets as a result.īoth subsetting and splitting are performed within a data step, and both make use of conditional logic. When subsetting a dataset, you will only have a single new dataset as a result.Ī split acts as a partition of a dataset: it separates the cases in a dataset into two or more new datasets. You can also think of this as "filtering" a dataset so that only some cases are included. In this tutorial, we use the following terms to refer to these two tasks:Ī subset is selection of cases taken from a dataset that match certain criteria.
![block variable sequential testing sas block variable sequential testing sas](http://openendedgroup.com/field/images/withExecutionRuler.png)
![block variable sequential testing sas block variable sequential testing sas](https://support.sas.com/documentation/cdl/en/anlystug/58352/HTML/default/images/c1504.gif)
When preparing data for analysis, you may need to "filter out" cases (rows) from your dataset, or you may need to divide a dataset into separate pieces.