fmtr
Easily Apply Formats to Data
Rebuilding SAS's formatting layer in R, one format specification at a time
◆Recent moves
- 10mo ago
Mean and standard error helper, plus best-format variants
Adds fmt_mean_stderr() alongside the existing mean and standard deviation helper, and handles the variations on the best specification that the previous release did not anticipate. The standard one-two of this package: add a SAS-derived format, then absorb how people actually write it.
View source ↗ - 11mo ago
SAS best. format reimplemented in fapply()
Recreates SAS's best. format, which picks a sensible numeric representation without the caller specifying width or decimals. A direct parity addition of the kind that defines this package's roadmap.
View source ↗ - 2y ago
Quarter format codes %q and %Q added
Introduces quarter format codes that base R simply does not provide, filling a gap that matters for any reporting on fiscal periods. Small in size, but it extends the format vocabulary rather than adjusting existing behaviour.
View source ↗ - 2y ago
Format lists become readable and writable files
Adds read.flist() and write.flist() so format lists persist to disk, allows single-item vector lookups, and lets a Factor column drive the as.factor property when converting data frames. Persisting format catalogues is what makes them reusable across programs, which is how they work in SAS.
View source ↗ - 2y ago
Documentation and examples expanded
Documentation and example improvements with no functional change. Notable only as the quiet gap between the 2023 and mid-2024 feature releases.
View source ↗ - 2y ago
value() can return results as a factor
Adds an as.factor parameter to value() so formatted results come back as factors, which controls ordering downstream in tables and plots. The same property later became settable from a data frame column.
View source ↗