avg_integrand#

View page source

Model for the Average Integrand#

Ordinary Differential Equation#

In the case where the rates do not depend on time, the dismod_ode ordinary differential equation is

\begin{eqnarray} S'(a) & = & - [ \iota(a) + \omega (a) ] S(a) + \rho(a) C(a) \\ C'(a) & = & + \iota(a) S(a) - [ \rho(a) + \chi(a) + \omega (a) ] C(a) \end{eqnarray}

with the initial condition \(C(0) = p_0\) and \(S(0) = 1 - p_0\). This equation is made more complicated by the fact that the rates vary with time as well as with each data point. The reason for the variation between data points due both to the random effects as well as the rate_value covariates.

Data or Avgint Table Notation#

i#

We use \(i\) to denote either, data_id for a row in the data table or, avgint_id for a row in the avgint table.

a_i#

We use \(a_i\) to denote the corresponding age_lower in the data table or avgint table .

b_i#

We use \(b_i\) to denote the corresponding age_upper in the data table or avgint table .

c_i#

We use \(c_i\) to denote the corresponding time_lower in the data table or avgint table .

d_i#

We use \(d_i\) to denote the corresponding time_upper in the data table or avgint table .

s_i#

We use \(s_i\) to denote the corresponding subgroup_id in the data table or avgint table .

g_i#

We use \(g_i\) to denote the group_id that \(s_i\) is part of.

Covariate Difference, x_ij#

We use \(x_{i,j}\) to denote the covariate difference for the i-th data point and the j-th covariate. Here i denotes a data_id in the data table and j denotes a covariate_id in the covariate table. The difference is the corresponding data table covariate value minus the covariate table reference value .

w_i#

We use \(w_i (a, t)\) for the weighting as a function of age and time that corresponds to the weight_id for this data_id .

n_i#

We use \(n_i\) to denote the corresponding node_id value.

Rate Functions#

Parent Rate, q_k#

We use \(k\) to denote a rate_id and \(q_k (a, t)\) the piecewise linear rate function for the corresponding to the parent rate . This is the model for the rate corresponding to the Parent Node and the reference value for the covariates; i.e. \(x_{i,j} = 0\). The adjusted rate r_ik is defined below.

Child Rate Effect, u_ik#

If the node for this data point \(n_i\) is a child node, or a descendant of a child node, \(u_{i,k} (a, t)\) is the piecewise linear random effect for the corresponding child and rate . If \(n_i\) is the parent node, there is no random effect for this data and \(u_{i,k} (a, t) = 0\). Otherwise \(n_i\) is not the parent node or a descendant of the parent node and the corresponding data is not used.

J_k#

We use \(J_k\) to denote the set of covariate_id values in the mulcov table such that the corresponding rate_id is equal to \(k\), mulcov_type is rate_value , and group_id equal to \(g_i\). These covariates that affect the k-th rate for this group of measurements.

Group Rate Covariate Multiplier, alpha_jk#

For each rate index \(k\), and each covariate index \(j \in J_k\), we use \(\alpha_{j,k} (a, t)\) to denote the piecewise linear function corresponding to the group covariate multiplier . Note that these are rate_value covariate multipliers specified by the mulcov table.

Subgroup Rate Covariate Multiplier, Delta alpha_jk#

For each rate index \(k\), and each covariate index \(j \in J_k\), we use \(\Delta \alpha_{j,k} (a, t)\) to denote the piecewise linear function corresponding to the \(s_i\) subgroup covariate multiplier .

Adjusted Rate, r_ik#

We define the adjusted k-th rate for the i-th data point by

\[r_{i,k} (a , t) = \exp \left \{ u_{i,k} (a, t) + \sum_{j \in J(k)} x_{i,j} [ \alpha_{j,k} (a, t) + \Delta \alpha_{j,k} (a, t) ] \right \} q_k ( a, t )\]

If \(n_i\) is the parent node, the random effects is zero \(u_{i,k} (a, t) = 0\). If this data point also has the reference value for the covariates, \(r_{i,k} (a, t) = q_k (a, t)\).

pini, p_i0(t)#

We use \(p_{i,0} (t)\) to denote the model value (as apposed to a measurement value) for prevalence at the initial age as a function of time. Note that this function is constant with respect to age \(a\); see pini . This is denoted by \(r_{i,0} (a, t)\) above.

iota_i(a,t)#

We use iota_i ( a , t ) and \(\iota_i (a,t)\) to denote the model value for adjusted susceptible incidence as a function of age and time; see iota . This is denoted by \(r_{i,1} ( a, t )\) above.

rho_i(a,t)#

We use rho_i ( a , t ) and \(\rho_i (a,t)\) to denote the model value for adjusted remission as a function of age and time; see rho . This is denoted by \(r_{i,2} ( a, t )\) above.

chi_i(a,t)#

We use chi_i ( a , t ) and \(\chi_i (a,t)\) to denote the model value for adjusted excess mortality (mortality due to the cause) as a function of age and time. This is denoted by \(r_{i,3} ( a, t )\) above.

omega_i(a,t)#

We use omega_i ( a , t ) and \(\omega_i (a,t)\) to denote the model value for adjusted other cause mortality as a function of age and time; see omega . This is denoted by \(r_{i,4} ( a, t )\) above.

S_i(a,t)#

We use \(S_i (a,t)\) to denote the model value for susceptible fraction of the population.

C_i(a,t)#

We use \(C_i (a,t)\) to denote the model value for with condition fraction of the population.

Differential Equation#

We drop the subscript \(i\) in the adjusted rates to simplify notation in the equations below. The with condition and susceptible fractions at age zero are

\[C (0, t) = p_0 (t) \; , \; S (0, t) = 1 - p_0 (t)\]

We use \(c\) to denote cohort; i.e., \(t = a + c\), Given the rates (initial prevalence is called a rate), the functions \(S (a,t)\) and \(C (a,t)\) for \(a > 0\) are defined by

\begin{eqnarray} ( \B{d} / \B{d} a ) S(a, a+c) & = & - [ \iota (a, a+c) + \omega (a, a+c) ] S(a, a+c) + \rho(a, a+c) C(a, a+c) \\ ( \B{d} / \B{d} a ) C(a, a+c) & = & + \iota(a, a+c) S(a, a+c) - [ \rho(a, a+c) + \chi(a, a+c) + \omega(a, a+c) ] C(a, a+c) \end{eqnarray}

Integrand, I_i(a,t)#

We use \(I_i (a, t)\) to denote the integrand as a function of age and time. Depending on the value of see integrand_id for data index \(i\), the function \(I_i (a, t)\) is defined below. The age and time arguments \((a, t)\) and the subscript \(i\) are dropped to simplify notation. The rates are adjusted rates. (Integrands that do not use \(S\), \(C\) or \(P\), do not require solving the differential equation.)

Sincidence#

The incidence rate relative to susceptible population is \(I = \iota\).

remission#

The remission rate is \(I = \rho\).

mtexcess#

The excess mortality rate is \(I = \chi\).

mtother#

The other cause mortality rate is \(I = \omega\).

mtwith#

The with condition mortality rate is \(I = \omega + \chi\).

susceptible#

The susceptible fraction of the population is \(I = S\).

withC#

The with condition fraction of the population is \(I = C\).

prevalence#

The prevalence of the condition is \(I = P = C / ( S + C )\).

Tincidence#

The incidence rate relative to the total population is \(I = \iota ( 1 - P )\).

mtspecific#

The cause specific mortality rate is \(I = \chi P\).

mtall#

The all cause mortality rate is \(I = \omega + \chi P\).

mtstandard#

The standardized mortality ratio is \(I = ( \omega + \chi ) / ( \omega + \chi P )\).

relrisk#

The relative risk is \(I = ( \omega + \chi ) / \omega\).

mulcov#

If the integrand_name is mulcov_ mulcov_id , \(I\) is the covariate multiplier corresponding to mulcov_id . In this case there are no covariate that affect the measurement.

Measurement Value Covariates#

K_i#

We use \(K_i\) to the set of covariate_id values in the mulcov table such that the corresponding integrand_id corresponds to \(I_i (a, t)\), mulcov_type is meas_value , and group_id equal to \(g_i\). These are the covariates that affect the i-th measurement value.

Group Measurement Covariate Multiplier, beta_j#

For each covariate index \(j \in K_i\), we use \(\beta_j (a, t)\) to denote the piecewise linear function corresponding to the group covariate multiplier . Note that these are meas_value covariate multipliers specified by the mulcov table.

Subgroup Measurement Covariate Multiplier, Delta beta_j#

For each covariate index \(j \in K_i\), we use \(\Delta \beta_j (a, t)\) to denote the piecewise linear function corresponding to the \(s_i\) subgroup covariate multiplier .

Measurement Effect#

The effect for the i-th measurement value, as a function of the fixed effects \(\theta\), is

\[E_i ( a, t ) = \sum_{j \in K_i} x_{i,j} [ \beta_j (a, t) + \Delta \beta_j (a, t) ]\]

Adjusted Integrand#

The adjusted integrand is the following function of age and time:

\[I_i (a, t) \; \exp \left[ E_i (a, t) \right]\]

Note that if \(I_i (a, t)\) is a covariate multiplier mulcov , the adjusted integrand is equal to \(I_i(a,t)\); i.e., there is no adjustment.

Weight Integral, wbar_i#

We use \(\bar{w}_i\) to denote the weight integral defined by

\[\bar{w}_i = \frac{1}{b_i - a_i} \frac{1}{d_i - c_i} \int_{a(i)}^{b(i)} \int_{c(i)}^{d(i)} w_i (a,t) \; \B{d} t \; \B{d} a\]

Average Integrand, A_i#

We use \(u\) and \(\theta\) to denote the vector of random effects and fixed effects respectively. The model for the i-th measurement, not counting integrand effects or measurement noise, is

\[A_i ( u , \theta ) = \frac{1}{b_i - a_i} \frac{1}{d_i - c_i} \left[ \int_{a(i)}^{b(i)} \int_{c(i)}^{d(i)} \frac{ w_i (a,t) }{ \bar{w}_i } I_i (a, t) \; \exp \left[ E_i (a, t) \right] \; \B{d} t \; \B{d} a \right] \;\]

Note that this is actually a weighted average of the integrand function \(I_i (a, t)\) times the total measurement covariate effect \(E_i (a, t)\) Also note that in the case where \(a(i) = b(i)\), \(c(i) = d(i)\), or both, the average is defined as the limiting value.