discretise_Manual: Discretise data using pre-defined break points

View source: R/tidyDiscretise.R

discretise_ManualR Documentation

Discretise data using pre-defined break points

Usage

discretise_Manual(
  df,
  continuousVar,
  discreteOutputVar,
  cutsDf,
  lowerBounded = FALSE,
  factorise = FALSE,
  noUnicode = ("tbl_sql" %in% class(df)),
  format = "%.4g",
  ...
)

Arguments

df

- may be grouped, in which case the value is interpreted as different types of continuous variable

continuousVar

- the columns that define the discrete subgroups of the data.

discreteOutputVar

- the name of the value to create in the dataframe

cutsDf

- manual break points as a dataframe containing cut points for every group (see cutsDfFromVector).

lowerBounded

- default FALSE, should the lower or upper values be included in the group

factorise

- convert discrete values into an ordered factor (alternative is a character string). This is only useful if you have a single set of cuts for all groups.

noUnicode

- by default unicode characters are not used for the label if the target is a dbplyr table

format

- a sprintf formatting string with one

a dataframe containing the discreteOutputVar column Discretise data using pre-defined break points


terminological/tidy-info-stats documentation built on Nov. 19, 2022, 11:23 p.m.