Learn R Programming

mosaic (version 0.13.0)

zscore: Compute z-scores

Description

Compute z-scores

Usage

zscore(x, na.rm = getOption("na.rm", FALSE))

Arguments

x
a numeric vector
na.rm
a logical indicating whether missing values should be removed

Examples

Run this code
iris %>% 
  group_by(Species) %>% 
  mutate(zSepal.Length = zscore(Sepal.Length)) %>% 
  head()

Run the code above in your browser using DataLab