Learn R Programming

formatters

[![Check

Copy Link

Version

Install

install.packages('formatters')

Monthly Downloads

4,326

Version

0.5.11

License

Apache License 2.0

Issues

Pull Requests

Stars

Forks

Maintainer

Joe Zhu

Last Published

April 9th, 2025

Functions in formatters (0.5.11)

font_lcpi

Calculate lines per inch and characters per inch for font
divider_height

Divider height
fmt_config

Format configuration
export_as_pdf

Export as PDF
export_as_rtf

Export as RTF
export_as_txt

Export a table-like object to plain (ASCII) text with page breaks
do_forced_paginate

Generic for performing "forced" pagination
format_value

Converts a (possibly compound) value into a string using the format information
font_spec

Font size specification
formatters-package

formatters Package
mf_strings

Getters and setters for aspects of MatrixPrintForm objects
nchar_ttype

Calculate font-specific string width
lab_name

Label, name, and format accessor generics
ifnotlen0

%||% (if length-0) alternative operator
matrix_form

Transform rtable to a list of matrices which can be used for outputting
list_formats

List of currently supported formats and vertical alignments
make_row_df

Make row layout summary data frames for use during pagination
nlines

Number of lines required to print a value
is.wholenumber

Check if a value is a whole number
mpf_to_rtf

Transform MatrixPrintForm to RTF
paginate_indices

Paginate a table-like object for rendering
page_lcpp

Determine lines per page (LPP) and characters per page (CPP) based on font and page type
propose_column_widths

Propose column widths based on the MatrixPrintForm of an object
pag_indices_inner

Find pagination indices from pagination info data frame
num_rep_cols

Number of repeated columns
padstr

Pad a string and align within string
pagdfrow

Create a row of a pagination data frame
open_font_dev

Activate font state
page_types

Supported named page types
pagination_algo

Pagination
ref_df_row

Create a row for a referential footnote information data frame
spread_integer

Spread an integer to a given length
spans_to_viscell

Transform a vector of spans (with duplication) into a visibility vector
sprintf_format

Specify text format via a sprintf format string
table_inset

Access or (recursively) set table inset
toString

Transform objects into string representations
test_matrix_form

Create spoof matrix form from a data frame
var_labels<-

Set label attributes of all variables in a data.frame
main_title

General title and footer accessors
round_fmt

Round and prepare a value for display
vert_pag_indices

Find column indices for vertical pagination
var_relabel

Copy and change variable labels of a data.frame
split_word_ttype

wrap string given a Truetype font
var_labels_remove

Remove variable labels of a data.frame
with_label

Return an object with a label attribute
var_labels

Get label attributes of variables in a data.frame
wrap_string

Wrap a string to a precise width
decimal_align

Decimal alignment
basic_pagdf

Basic/spoof pagination info data frame
MatrixPrintForm

Constructor for Matrix Print Form
default_horizontal_sep

Default horizontal separator
MatrixPrintForm-class

Class for Matrix Print Form
print,ANY-method

Print
default_page_number

Default page number format
DM

DM data
ex_adsl

Simulated CDISC-like data for examples
check_formats

Check if a format or alignment is supported