Calculates percentage of cases for provided variable and
criteria specified in subset argument. Function
accepts numeric, factor and logical variables for
x parameter. If numeric and/or factor is provided,
subsetting can be achieved via subset argument.
Depending on value of na.rm argument, either valid
(na.rm = TRUE) or all cases (na.rm = FALSE)
are taken into account. By passing logical variable to
x, a sum of (TRUE) elements is calculated
instead, and valid percents are used (NA are
excluded).