Skip to contents

Creating initial values for an agonist sigmoid model parameters that can be passed to the sigmoid_model() along with the sigmoid_antagonist_formula() and sigmoid_antagonist_prior().

Usage

sigmoid_antagonist_init(
  ic50 = function() stats::runif(n = 1, min = -7, max = -5),
  hill = function() stats::runif(n = 1, min = -1.2, max = -0.8),
  top = function() stats::runif(n = 1, min = 0.8, max = 1.2),
  bottom = function() stats::runif(n = 1, min = -0.2, max = 0.2),
  ...
)

Arguments

ic50

numeric or numeric returning function units of the treatment. If the treatment is log_dose, the default value of -6 corresponds 1e-6 molar = 1 μM

hill

numeric or numeric returning function with units response/log_dose

top

numeric or numeric returning function in units of the response

bottom

numeric or numeric returning function in units of the response

...

additional parameter initialization. Each named argument should be a function that returns an numeric array of length 1, see rstan_default_init() to use the rstan default init.

Value

input for [brm][brms::brm](init = ...)

Examples

if (FALSE) { # \dontrun{
# Consider an inhibitor that has a min response around 50%, IC50 is estimated
# to be around 1 nM, maximum response is known to be around 1,
init <- BayesPharma::sigmoid_antagonist_init(
  ec50 = -9,
  bottom = 0.5)

# By default rstan initializes unspecified initial values to be uniformly at
# random in the range (-2, 2) on the unconstrained scale. For the default
# distributional response, family=gaussian(), the shape parameter sigma' is
# bounded below by zero through this transformation Y = log(X - 0). So, to
# explicitly give the default initialization for 'sigma', we can use
init <- BayesPharma::sigmoid_antagonist_init(
  sigma = BayesPharma::rstan_default_init(lb = 0))
} # }