rsadd                package:relsurv                R Documentation

_F_i_t _a_n _A_d_d_i_t_i_v_e _m_o_d_e_l _f_o_r _R_e_l_a_t_i_v_e _S_u_r_v_i_v_a_l

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

     The function fits an additive model to the data. The methods
     implemented are the maximum likelihood method, a glm model with a
     'binomial' error and a glm model with a 'poisson' error.

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

     rsadd(formula, data=parent.frame(), ratetable = survexp.us,
           int, na.action, method, init,centered,control,...)

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

 formula: a formula object, with the response on the left of a '~'
          operator, and the terms on the right. The terms consist of
          predictor variables separated by the '+' operator, along with
          a 'ratetable' term. The 'ratetable' term matches each subject
          to his/her expected cohort. If the variables are organized
          and named in the same way as in the population tables, the
          'ratetable' term can be omitted. The response must be a
          survival object as returned by the 'Surv' function. The time
          must be in days. 

    data: a data.frame in which to interpret the variables named in the
          'formula'. 

ratetable: a table of event rates, organized as a 'ratetable' object,
          such as 'survexp.us'.  

     int: either a single value denoting the number of follow-up years
          or a vector specifying the intervals (in years) in which the
          hazard is constant (the times that are bigger than 'max(int)'
          are censored. If missing, the intervals are set to be one
          year  long and include the maximum observed follow-up time. 

na.action: a missing-data filter function, applied to the model.frame,
          after any subset argument has been used.  Default is
          'options()$na.action'. 

  method: 'glm.bin' or 'glm.poi' for a glm model and 'max.lik' for the
          maximum likelihood model (default). 

    init: vector of initial values of the iteration.  Default initial
          value is zero for all variables. 

centered: if 'TRUE', all the variables are centered before fitting and
          the baseline excess hazard is calculated accordingly. Default
          is 'FALSE'. 

 control: a list of parameters for controlling the fitting process. 
          See the documentation for 'glm.control' for details. 

     ...: other arguments will be passed to 'glm.control'.

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

     An object of class 'rsadd'. In the case of 'method="glm.bin"' and
     'method="glm.poi"' the class also inherits from 'glm' which 
     inherits from the class 'lm'. Objects of this class have methods
     for the functions 'print' and 'summary'. An object of class
     'rsadd' is a list containing at least the following components: 

    data: the original data, along with the variables defined in the
          rate table

  warnme: the number of groups with the observed number of deaths is
          smaller than the expected.

ratetable: the ratetable used.

     int: the maximum time (in years) used. All the events at and after
          this value are censored.

  method: the fitting method that was used.

linear.predictors: the vector of linear predictors, one per subject.

  groups: life tables for groups specified by the covariates.

_R_e_f_e_r_e_n_c_e_s:

     Dickman P.W., Sloggett A., Hills M., Hakulinen T. "Regression
     models for relative survival." _Statistics in Medicine,_ 2004.

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

     'rstrans', 'rsmul'

_E_x_a_m_p_l_e_s:

     data(slopop)
     data(rdata)
     rsadd(Surv(time,cens)~sex+as.factor(agegr)+ratetable(age=age*365,sex=sex,year=year),
           ratetable=slopop,data=rdata,int=5)

