The st object will collect various configuration settings and pass those to stable() when the object is passed to st_make().

st_new(x, ...)

# S3 method for class 'data.frame'
st_new(x, ...)

# S3 method for class 'pmtable'
st_new(x, ...)

st_data(x, ...)

Arguments

x

either a data frame or an object of class pmtable; see details.

...

additional arguments which will eventually get passed to the table render function (e.g. stable() or stable_long()).

Value

And object with class stobject which can get piped to other functions. The pmtable method returns an object that also has class ptobject.

Details

Methods are included for data.frame and pmtable, an object that comes from one of the data summary functions (e.g. pt_cont_wide(), or pt_cat_long() or pt_demographics()).

If using the data frame method, the user should filter or subset so that the data (x) contains exactly the rows (and columns) to be processed; pmtables will not add or remove rows prior to processing x.

Examples

ob <- st_new(ptdata())
ob <- st_data(ptdata())

ob <- st_new(pt_data_inventory(pmt_obs))