Using filtersOxonStat provides a powerful filtering mechanism to allow you to select the data you wish to analyse or graph. At the same time Filters are easy to understand and configure.
Filters allow a subset of the observations in the current dataset, which match specific conditions, to be selected. For example 'All males' or 'Weight greater than 70'.
Filters belong to a variable and consist of a name, an operator and a constant. The name allow you to select them for analysis.
The following operators are available, they include observations when the value of the variable is:
| = | equal to the constant |
| <> | not equal the constant |
| > | greater than the constant |
| < | less than the constant |
| >= | greater than or equal to the constant |
| <= | less than or equal to the constant |
| Variable | Name | Operator | Constant | Action |
|---|---|---|---|---|
| Age | 60 or more | >= | 60 | includes observations where the Age variable is greater than or equal to 60 |
| Age | Younger than 60 | < | 60 | includes observations where the Age variable is less than 60 |
Any number of filters can be defined for each column in a dataset. Filters work with any type of data column. Filters are defined in the Filters panel of the Column properties dialog:
For Code list variables OxonStat will automatically create a set of filters. For each entry in the code list, a pair of filters are created. One equal to the code and another not equal to the code.
For example, if a variable called Gender is created with values of 1 as Male and 2 as Female, OxonStat would produce the following filters:
Each statistical test or graphics option presents a dialog with a Filters tab. If filters are not enabled, then all rows in the Dataset are included, the tab will look like this:
Clicking the "Use filters" checkbox will open the filter selector as follows. The filter names shown are prefixed by the variable name to avoid ambiguity:
One or more filters may be selected if desired using command-click.
If more than one filter is selected, they may be applied in two distinct ways:
The Filters selected can come from any number of variables in the Dataset.
Filter preview will show the rows in the dataset that would be included in the analysis using the currently selected filters and combination method. You can enlarge the dialog to make the Filter preview panel larger and easier to view.
"Age: 60 or more" and "Gender: = Male" are selected and "Include rows if all selected filters apply" is used. Rows are only included if the row is a male who is aged 60 year old or more.
"Age: 60 or more" and "Gender: = Male" are selected and "Include rows if any selected filter applies" is used. Rows are included if the row contains a male or a person, of any gender, who is aged 60 year old or more.
"Gender: = Male" and "Gender: = Female" are selected and "Include rows if all selected filters apply" is used. No rows would be included as the Gender column cannot contain a row that is set to both Male and Female simultaneously.