$$ \newcommand{\esp}[1]{\mathbb{E}\left(#1\right)} \newcommand{\var}[1]{\mbox{Var}\left(#1\right)} \newcommand{\deriv}[1]{\dot{#1}(t)} \newcommand{\prob}[1]{ \mathbb{P}\!(#1)} \newcommand{\eqdef}{\mathop{=}\limits^{\mathrm{def}}} \newcommand{\by}{\boldsymbol{y}} \newcommand{\bc}{\boldsymbol{c}} \newcommand{\bpsi}{\boldsymbol{\psi}} \def\pmacro{\texttt{p}} \def\like{{\cal L}} \def\llike{{\cal LL}} \def\logit{{\rm logit}} \def\probit{{\rm probit}} \def\one{{\rm 1\!I}} \def\iid{\mathop{\sim}_{\rm i.i.d.}} \def\simh0{\mathop{\sim}_{H_0}} \def\df{\texttt{df}} \def\res{e} \def\xomega{x} \newcommand{\argmin}[1]{{\rm arg}\min_{#1}} \newcommand{\argmax}[1]{{\rm arg}\max_{#1}} \newcommand{\Rset}{\mbox{$\mathbb{R}$}} \def\param{\theta} \def\setparam{\Theta} \def\xnew{x_{\rm new}} \def\fnew{f_{\rm new}} \def\ynew{y_{\rm new}} \def\nnew{n_{\rm new}} \def\enew{e_{\rm new}} \def\Xnew{X_{\rm new}} \def\hfnew{\widehat{\fnew}} \def\degree{m} \def\nbeta{d} \newcommand{\limite}[1]{\mathop{\longrightarrow}\limits_{#1}} \def\ka{k{\scriptstyle a}} \def\ska{k{\scriptscriptstyle a}} \def\kel{k{\scriptstyle e}} \def\skel{k{\scriptscriptstyle e}} \def\cl{C{\small l}} \def\Tlag{T\hspace{-0.1em}{\scriptstyle lag}} \def\sTlag{T\hspace{-0.07em}{\scriptscriptstyle lag}} \def\Tk{T\hspace{-0.1em}{\scriptstyle k0}} \def\sTk{T\hspace{-0.07em}{\scriptscriptstyle k0}} \def\thalf{t{\scriptstyle 1/2}} \newcommand{\Dphi}[1]{\partial_\pphi #1} \def\asigma{a} \def\pphi{\psi} \newcommand{\stheta}{{\theta^\star}} \newcommand{\htheta}{{\widehat{\theta}}} $$


1 Polynomial regression

The file ratWeight.csv consists of rat weights measured over 14 weeks during a subchronic toxicity study related to the question of genetically modified (GM) corn.

We will only consider the weight of rat B38625.

Based on this data, our objective is to build a regression model of the form

\[y_j = f(x_j) + e_j \quad ; \quad 1 \leq j \leq n\]

We will restrict ourselves to polynomial regression, by considering functions of the form \[ \begin{aligned} f(x) &= f(x ; c_0, c_1, c_2, \ldots, c_d) \\ &= c_0 + c_1 x + c_2 x^2 + \ldots + c_d x^d \end{aligned} \]

Fit the ``best?????? polynomial to this data


2 Nonlinear regression

  1. Load the ratWeight.csv datafile and plot the weight of the females of the control group

  2. Select the ID B38837 and fit a polynomial model to the growth curve of this female rat.

  3. Fit a Gompertz model \(f_1(t) = A e^{-b e^{-k\, t}}\) to this data.

  4. Fit the two following growth models:

Asymptotic regression model: \[f_2(t) = A \left( 1 - b\, e^{-k\, t} \right)\]

Logistic curve: \[f_3(t) = \frac{A}{1 + e^{-\gamma( t-\tau)}}\]

  1. Propose two other parametrizations of the asymptotic regression model which involves
  1. the weight at birth \(w_0\) (when \(t=0\)), the limit weight \(w_\infty\) (when \(t\to \infty\)) and \(k\)
  2. the weight at birth, the weight at the end of the study \(w_{14}\) and the ratio \(r=(w_{14}-W_{7})/(w_7 - w_0)\)

Can we compare these models?

  1. We will now use model \(f_{2a}\). Check that the estimate of \(\beta=(w_0, w_\infty, k)\) obtained with the nls function is the least squares estimate.

  2. Check that this estimate is also the least squares estimate of the linearized model. Then, how are computed the standard errors of \(\hat\beta\)?

  3. Compute 90% confidence intervals for the model parameters using several approaches (linearization, parametric bootstrap, profile likelihood)

  4. Compute a 90% confidence interval for the predicted weight and a 90% prediction interval for the measured weight using the delta method.

  5. Compare the predicted weight of this rat with the predicted weight for ID B38837.