drm                   package:drc                   R Documentation

_F_i_t_t_i_n_g _d_o_s_e-_r_e_s_p_o_n_s_e _m_o_d_e_l_s

_D_e_s_c_r_i_p_t_i_o_n:

     A general model fitting function for
     concentration/dose/time-response models.

_U_s_a_g_e:

       drm(formula, curveid, pmodels, weights, data = NULL, subset, fct, 
       type = c("continuous", "binomial", "Poisson", "quantal", "survival"), bcVal = NULL, bcAdd = 0, 
       start, na.action = na.fail, robust = "mean", logDose = NULL, 
       control = drmc(), lowerl = NULL, upperl = NULL, separate = FALSE)

_A_r_g_u_m_e_n_t_s:

 formula: a symbolic description of the model to be fit. Either of the
          form 'response ~ dose'  or as a data frame with response
          values in first column and dose values in second column.

 curveid: a numeric vector or factor containing the grouping of the
          data.

 pmodels: a data frame with a many columns as there are parameters in
          the non-linear function.  Or a list containing a formula for
          each parameter in the non-linear function.

 weights: a numeric vector containing weights.

    data: an optional data frame containing the variables in the model.

  subset: an optional vector specifying a subset of observations to be
          used in the fitting process.

     fct: a list with three or more elements specifying the non-linear
          function, the accompanying self starter function, the names
          of the parameter in the non-linear function and,  optionally,
          the first and second derivatives as well as information used
          for calculation of ED values. Currently available functions
          include, among others, the four- and five-parameter
          log-logistic models  'LL.4', 'LL.5' and the Weibull model
          'W1.4'. Use 'getMeanFunctions' for a full list.

   bcVal: a numeric value specifying the lambda parameter to be used in
          the Box-Cox transformation.

   bcAdd: a numeric value specifying the constant to be added on both
          sides prior to Box-Cox transformation.  The default is 0.

    type: a character string specifying the data type: continuous is
          the only option currently.

   start: an optional numeric vector containing starting values for all
          mean parameters in the model.  Overrules any self starter
          function.

na.action: a function which indicates what should happen when the data
          contain 'NA's.   The default is 'link{na.fail}'. To omit
          'NA's use 'na.omit'.

  robust: a character string specifying the rho function for robust
          estimation. Default is non-robust  least squares estimation
          ("mean"). Available robust methods are: median estimation
          ("median"),  least median of squares ("lms"), least trimmed
          squares ("lts"), metric trimming ("trimmed"),  metric
          winsorizing ("winsor") and Tukey's biweight ("tukey").

 logDose: a numeric value or NULL. If log doses value are provided the
          base of the logarithm should be specified (exp(1) for the
          natural logarithm and 10 for 10-logarithm).

 control: a list of arguments controlling constrained optimisation
          (zero as boundary),  maximum number of iteration in the
          optimisation, relative tolerance in the optimisation,
          warnings issued during the optimisation.

  lowerl: a numeric vector of lower limits for all parameters in the
          model  (the default corresponds to minus infinity for all
          parameters).

  upperl: a numeric vector of upper limits for all parameters in the
          model  (the default corresponds to plus infinity for all
          parameters).

separate: logical value indicating whether curves should be fit
          separately (independent of each other).

_D_e_t_a_i_l_s:

     This function uses the function 'optim' for the minimisation. The
     control arguments are specified using  the function 'drmc'.

     For robust estimation MAD (median abslolute deviance) is used to
     estimate the residual variance.  

     Setting 'lowerl' and/or 'upperl' automatically invokes constrained
     optimisation.

_V_a_l_u_e:

     An object of class 'drc'.

_N_o_t_e:

     The 'curve' argument is subsequently used for plotting
     dose-response curves. For large datasets  it need not represent
     the actual curves, but it could represent several curves having
     the parameters  (to avoid too many curves in the plot). The same
     applies for use with the function 'ED.drc'  and 'SI'.

     The columns of a data frame argument to 'pmodels' are
     automatically converted into factors.  This does not happen if a
     list is specified.

_A_u_t_h_o_r(_s):

     Christian Ritz and Jens C. Streibig

_S_e_e _A_l_s_o:

     Examples using 'drm' found in the help pages of 'secalonic',
     'ryegrass',  and many other datasets and functions in 'drc'.

