rat.growth: Rat Growth Data

Description Usage Format Source References Examples

Description

Data on the weights of 30 rats each week for 5 weeks.

Usage

1

Format

A data frame with 150 observations on the following 3 variables.

rat

a factor with levels 1-30

week

takes values 0-4

y

rat weight (units unspecified)

Source

Gelfand, A. E., Hills, S. E., Racine-Poon, A. and Smith, A. F. M. (1990) Illustration of Bayesian inference in normal data models using Gibbs sampling. Journal of the American Statistical Association, 85, 972–985.

References

Davison, A. C. (2003) Statistical Models. Cambridge University Press. Page 460.

Examples

1
2
3
4
5
6
7
8
9
data(rat.growth)
library(nlme)
rat.fit <- groupedData( y~poly(week,2) | rat,
                   data = rat.growth,
                   labels = list( x = "Week",
                     y = "Weight" ),
                   units = list( x = "", y = "(?)") )

summary(lme(rat.fit))

Example output

Loading required package: ellipse
Linear mixed-effects model fit by REML
 Data: rat.fit 
       AIC      BIC    logLik
  1013.358 1043.262 -496.6789

Random effects:
 Formula: ~poly(week, 2) | rat
 Structure: General positive-definite
               StdDev    Corr         
(Intercept)    14.231960 (Intr) p(,2)1
poly(week, 2)1 66.616174  0.586       
poly(week, 2)2 22.953028 -0.329  0.184
Residual        3.295615              

Fixed effects: y ~ poly(week, 2) 
                  Value Std.Error  DF  t-value p-value
(Intercept)    242.5867  2.612284 118 92.86380       0
poly(week, 2)1 749.4006 12.600988 118 59.47158       0
poly(week, 2)2 -39.6215  5.331272 118 -7.43191       0
 Correlation: 
               (Intr) p(,2)1
poly(week, 2)1  0.563       
poly(week, 2)2 -0.257  0.139

Standardized Within-Group Residuals:
        Min          Q1         Med          Q3         Max 
-2.39388522 -0.36081136 -0.02487025  0.34840295  2.65195119 

Number of Observations: 150
Number of Groups: 30 

SMPracticals documentation built on May 2, 2019, 11:12 a.m.