proportion.misclassified: Calculate the Proportion Misclassifed

Description Usage Arguments Value Note Author(s) Examples

Description

Calculates the proportion misclassified for a set of categorical values.

Usage

1

Arguments

x

A categorical vector.

na.rm

If TRUE (default) observations with a missing value of x are removed before applying the test.

Value

Numeric. Returns the value of the calculated proportion misclassified. Multiply by 100 for the percentage misclassified.

Note

The proportion misclassified represents the percentage of observations that would have to swap category in order to achieve an even distribution of obsevations across categories. It is also known as the Index of Dissimilarity, althogh the IoD is normally used to compare the difference between the distribution of two groups across the same set of categories, rather than the difference of the distribution of one group and from a theoretical uniform distribution.

Author(s)

Paul Williamson

Examples

1
2
## Calculate the proportion misclassifed
proportion.misclassified(survey$Age)

DrPaulWilliamson/ENVS450 documentation built on May 9, 2019, 3:23 a.m.