Learn R Programming

MVar (version 2.0.4)

CoefVar: Coefficient of variation of the data.

Description

Find the coefficient of variation of the data, either overall or per column.

Usage

CoefVar(Data, Type = 1)

Arguments

Data

Data to be analyzed.

Type

1 Coefficient of overall variation (default), 2 Coefficient of variation per column.

Value

Coefficient of variation, either overall or per column.

References

FERREIRA, D. F.; Estatistica Basica. 2 ed. rev. Lavras: UFLA, 2009. 664 p.

Examples

Run this code
# NOT RUN {
data(DataQuan) # data set

Data <- DataQuan[,2:8]

Resp <- CoefVar(Data, Type = 1) # Coefficient of overall variation
round(Resp,2)

Resp <- CoefVar(Data, Type = 2) # Coefficient of variation per column
round(Resp,2)
# }

Run the code above in your browser using DataLab