cv: Coefficient of Variation Function

View source: R/coefficient_of_variation.R

cvR Documentation

Coefficient of Variation Function

Description

This function calculates the coefficient of variation of a numbers vector.

Usage

cv(x = NULL, learn = FALSE, interactive = FALSE)

Arguments

x

Optional numeric vector (not needed for interactive mode)

learn

Logical, if TRUE shows step-by-step explanation

interactive

Logical, if TRUE enables interactive practice mode

Value

The coefficient of variation of the vector (for non-interactive mode)

Examples

data <- c(10,4,5,7,3,4,1)

# Simple calculation
cv(data)

# Learning mode
cv(data, learn = TRUE)

# Interactive mode
if(interactive()){
cv(interactive = TRUE)
}


UAHDataScienceSF documentation built on April 3, 2025, 10:44 p.m.