You can show averages on tables for categorical variables without having to make another table, see How to Calculate an Average Value from Categorical Data in Displayr. This article describes how to show the Average in a table including a Don't know or a similarly labeled Value (Unsure below) which includes the category:
to one where the category is still shown but is removed from the Averages and any other Statistics created using the underlying values.
- A data set containing one or more categorical or numeric variables that contains a 'Don't know' or a similarly labeled category that you want to excluded from Statistics that use the underlying categorical Value.
Phrases that are identified as Don't Know type responses are ones that contain one or more of:
- dont know
- don't know
- don t know
- not sure
- do not know
- no idea
- not applicable
The matching of these is not case sensitive.
Additionally, where a label is, in its entirety, NA or na, it is treated as a Don't Know.
1. You can select one or more tables/variables or an entire data set in your document. Any Don't Know categories within the selected object(s) will be removed.
2. From the toolbar menu, select Anything > Data > Variables > Modify > Recode > Set the Value of Don't Knows to NaN.