resolve_number_marks: Resolve number format marks

View source: R/number_utils.R

resolve_number_marksR Documentation

Resolve number format marks

Description

Converts a number_format specification into a list of big.mark and decimal.mark values used by all downstream formatting functions. Supports named presets, custom two-element vectors, and the global summata.number_format option.

Usage

resolve_number_marks(number_format = NULL)

Arguments

number_format

Character string specifying a named preset, a two-element character vector c(big.mark, decimal.mark), or NULL to use the global option (falling back to "us").

Named presets:

"us"

Comma thousands, period decimal: 1,234.56

"eu"

Period thousands, comma decimal: 1.234,56

"space"

Thin-space thousands, period decimal: 1 234.56 (SI/ISO 31-0 standard)

"none"

No thousands separator, period decimal: 1234.56

Custom vector: c(",", ".") or c(".", ",") etc. The first element is big.mark, the second is decimal.mark.

Value

A list with components:

big.mark

Character string for thousands separator.

decimal.mark

Character string for decimal separator.


summata documentation built on May 7, 2026, 5:07 p.m.