Learn R Programming

metalite.ae (version 0.1.2)

fmt_pct: Format percentage

Description

Format percentage

Usage

fmt_pct(x, digits = 1, pre = "(", post = ")")

Value

A numeric vector with the expected format.

Arguments

x

A numeric vector.

digits

Number of digits.

pre

Text before the number.

post

Text after the number.

Examples

Run this code
fmt_pct(c(1, 1.52, 0.3, 100))

Run the code above in your browser using DataLab