percent {lvmisc}R Documentation

percent vector

Description

Creates a double vector that represents percentages. When printed, it is multiplied by 100 and suffixed with ⁠%⁠.

Usage

percent(x = double())

is_percent(x)

as_percent(x)

Arguments

x
  • For percent(): A numeric vector

  • For is_percent(): An object to test.

  • For as_percent(): An object to cast.

Value

An S3 vector of class lvmisc_percent.

Examples

percent(c(0.25, 0.5, 0.75))

[Package lvmisc version 0.1.2 Index]