dosescalett: Rescaling dose variables acc. to Tukey et al. (1985)

Description Usage Arguments Value

View source: R/dosescalett.R

Description

Add rescaled dose variables to a data.frame.

Usage

1
2
3
dosescalett(data, dose, 
scaling = c("ari", "ord", "log", "arilog"),
sep = "", d0shift = 1)

Arguments

data

a data.frame

dose

a single charcater string, naming the (numeric) variable in data that is to be rescaled

scaling

A vector of character strings, naming the options for rescaling the variable specified in dose: "ari": no rescaling, "ord": ranks of dose levels, "log": log-transformed dose levels, "arilog": log-transformned dose levels, with interpolated dose score for 0, "high.vs.low": dose coerced to a factor, and only highest and lowest dose level retained, all others set NA, "treat": dose coerced to a factor, all levels retained with the option to apply multiple contrast tests to the treatment levels

sep

an optional separator for the names of the rescaled variables

d0shift

an optional factor, that is multiplied with the interpolated dose score for dose = 0 in option scaling="arilog"; ignored in all other options for rescaling

Value

A list containing

data

the input data.frame, with rescaled variables added as colummns

transnam

a vector of names of the re-scaled variables

scaling

the scaling options, as input


tukeytrend documentation built on March 13, 2020, 5:06 p.m.