1### $Id: ChickWeight.R,v 1.1 2003/12/11 07:16:04 ripley Exp $ 2### Data on the growth of chicks on different diets. 3### Hand and Crowder (1996), Table A.2, p. 172 4"ChickWeight" <- 5 structure(list( 6 weight = c(42, 51, 59, 64, 76, 93, 106, 125, 149, 7 171, 199, 205, 40, 49, 58, 72, 84, 103, 122, 138, 162, 187, 209, 8 215, 43, 39, 55, 67, 84, 99, 115, 138, 163, 187, 198, 202, 42, 9 49, 56, 67, 74, 87, 102, 108, 136, 154, 160, 157, 41, 42, 48, 10 60, 79, 106, 141, 164, 197, 199, 220, 223, 41, 49, 59, 74, 97, 11 124, 141, 148, 155, 160, 160, 157, 41, 49, 57, 71, 89, 112, 146, 12 174, 218, 250, 288, 305, 42, 50, 61, 71, 84, 93, 110, 116, 126, 13 134, 125, 42, 51, 59, 68, 85, 96, 90, 92, 93, 100, 100, 98, 41, 14 44, 52, 63, 74, 81, 89, 96, 101, 112, 120, 124, 43, 51, 63, 84, 15 112, 139, 168, 177, 182, 184, 181, 175, 41, 49, 56, 62, 72, 88, 16 119, 135, 162, 185, 195, 205, 41, 48, 53, 60, 65, 67, 71, 70, 17 71, 81, 91, 96, 41, 49, 62, 79, 101, 128, 164, 192, 227, 248, 18 259, 266, 41, 49, 56, 64, 68, 68, 67, 68, 41, 45, 49, 51, 57, 19 51, 54, 42, 51, 61, 72, 83, 89, 98, 103, 113, 123, 133, 142, 20 39, 35, 43, 48, 55, 62, 65, 71, 82, 88, 106, 120, 144, 157, 41, 21 47, 54, 58, 65, 73, 77, 89, 98, 107, 115, 117, 40, 50, 62, 86, 22 125, 163, 217, 240, 275, 307, 318, 331, 41, 55, 64, 77, 90, 95, 23 108, 111, 131, 148, 164, 167, 43, 52, 61, 73, 90, 103, 127, 135, 24 145, 163, 170, 175, 42, 52, 58, 74, 66, 68, 70, 71, 72, 72, 76, 25 74, 40, 49, 62, 78, 102, 124, 146, 164, 197, 231, 259, 265, 42, 26 48, 57, 74, 93, 114, 136, 147, 169, 205, 236, 251, 39, 46, 58, 27 73, 87, 100, 115, 123, 144, 163, 185, 192, 39, 46, 58, 73, 92, 28 114, 145, 156, 184, 207, 212, 233, 39, 48, 59, 74, 87, 106, 134, 29 150, 187, 230, 279, 309, 42, 48, 59, 72, 85, 98, 115, 122, 143, 30 151, 157, 150, 42, 53, 62, 73, 85, 102, 123, 138, 170, 204, 235, 31 256, 41, 49, 65, 82, 107, 129, 159, 179, 221, 263, 291, 305, 32 39, 50, 63, 77, 96, 111, 137, 144, 151, 146, 156, 147, 41, 49, 33 63, 85, 107, 134, 164, 186, 235, 294, 327, 341, 41, 53, 64, 87, 34 123, 158, 201, 238, 287, 332, 361, 373, 39, 48, 61, 76, 98, 116, 35 145, 166, 198, 227, 225, 220, 41, 48, 56, 68, 80, 83, 103, 112, 36 135, 157, 169, 178, 41, 49, 61, 74, 98, 109, 128, 154, 192, 232, 37 280, 290, 42, 50, 61, 78, 89, 109, 130, 146, 170, 214, 250, 272, 38 41, 55, 66, 79, 101, 120, 154, 182, 215, 262, 295, 321, 42, 51, 39 66, 85, 103, 124, 155, 153, 175, 184, 199, 204, 42, 49, 63, 84, 40 103, 126, 160, 174, 204, 234, 269, 281, 42, 55, 69, 96, 131, 41 157, 184, 188, 197, 198, 199, 200, 42, 51, 65, 86, 103, 118, 42 127, 138, 145, 146, 41, 50, 61, 78, 98, 117, 135, 141, 147, 174, 43 197, 196, 40, 52, 62, 82, 101, 120, 144, 156, 173, 210, 231, 44 238, 41, 53, 66, 79, 100, 123, 148, 157, 168, 185, 210, 205, 45 39, 50, 62, 80, 104, 125, 154, 170, 222, 261, 303, 322, 40, 53, 46 64, 85, 108, 128, 152, 166, 184, 203, 233, 237, 41, 54, 67, 84, 47 105, 122, 155, 175, 205, 234, 264, 264), 48 Time = c(0, 2, 4, 6, 49 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 50 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 51 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 52 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 53 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 54 14, 16, 18, 20, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 55 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 56 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 57 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 58 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 0, 2, 4, 6, 59 8, 10, 12, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 0, 60 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 61 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 62 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 63 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 64 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 65 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 66 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 67 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 68 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 69 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 70 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 71 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 72 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 73 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 74 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 75 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 76 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 77 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 0, 2, 4, 6, 8, 10, 78 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 79 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 80 10, 12, 14, 16, 18, 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 81 20, 21, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 21), 82 Chick = structure(ordered(c(15, 83 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 17, 17, 17, 17, 17, 84 17, 17, 17, 17, 17, 17, 17, 14, 14, 14, 14, 14, 14, 14, 14, 14, 85 14, 14, 14, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 18, 86 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 12, 12, 12, 12, 12, 87 12, 12, 12, 12, 12, 12, 12, 20, 20, 20, 20, 20, 20, 20, 20, 20, 88 20, 20, 20, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 5, 5, 5, 5, 5, 5, 89 5, 5, 5, 5, 5, 5, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 13, 13, 90 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 16, 16, 16, 16, 16, 16, 91 16, 16, 16, 16, 16, 16, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 19, 92 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 3, 3, 3, 3, 3, 3, 93 3, 3, 2, 2, 2, 2, 2, 2, 2, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 94 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 6, 6, 6, 95 6, 6, 6, 6, 6, 6, 6, 6, 6, 30, 30, 30, 30, 30, 30, 30, 30, 30, 96 30, 30, 30, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 24, 97 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 21, 21, 21, 21, 21, 98 21, 21, 21, 21, 21, 21, 21, 28, 28, 28, 28, 28, 28, 28, 28, 28, 99 28, 28, 28, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 25, 100 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 26, 26, 26, 26, 26, 101 26, 26, 26, 26, 26, 26, 26, 29, 29, 29, 29, 29, 29, 29, 29, 29, 102 29, 29, 29, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 34, 103 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 37, 37, 37, 37, 37, 104 37, 37, 37, 37, 37, 37, 37, 31, 31, 31, 31, 31, 31, 31, 31, 31, 105 31, 31, 31, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 40, 106 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 33, 33, 33, 33, 33, 107 33, 33, 33, 33, 33, 33, 33, 32, 32, 32, 32, 32, 32, 32, 32, 32, 108 32, 32, 32, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 35, 109 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 38, 38, 38, 38, 38, 110 38, 38, 38, 38, 38, 38, 38, 44, 44, 44, 44, 44, 44, 44, 44, 44, 111 44, 44, 44, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 43, 112 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 41, 41, 41, 41, 41, 113 41, 41, 41, 41, 41, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 114 42, 47, 47, 47, 47, 47, 47, 47, 47, 47, 47, 47, 47, 45, 45, 45, 115 45, 45, 45, 45, 45, 45, 45, 45, 45, 50, 50, 50, 50, 50, 50, 50, 116 50, 50, 50, 50, 50, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 117 46, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48), levels=1:50), 118 class = c("ordered", "factor"), 119 .Label = c("18", "16", "15", "13", "9", "20", "10", 120 "8", "17", "19", "4", "6", "11", "3", "1", "12", "2", "5", "14", 121 "7", "24", "30", "22", "23", "27", "28", "26", "25", "29", "21", 122 "33", "37", "36", "31", "39", "38", "32", "40", "34", "35", "44", 123 "45", "43", "41", "47", "49", "46", "50", "42", "48")), 124 Diet = structure(factor(c(1, 125 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 126 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 127 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 128 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 129 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 130 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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 3, 3, 3, 3, 3, 3, 4, 4, 4, 147 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 148 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 149 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 150 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 151 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 152 4, 4, 4, 4, 4, 4, 4, 4, 4, 4), levels=1:4), class = "factor", 153 .Label = c("1", "2", "3", "4"))), 154row.names = 1:578, 155class = c("nfnGroupedData", "nfGroupedData", "groupedData", "data.frame"), 156formula = weight ~ Time | Chick, 157outer = ~ Diet, 158labels = list(x = "Time", y = "Body weight"), 159units = list(x = "(days)", y = "(gm)")) 160 161environment(attr(ChickWeight, "formula")) <- emptyenv() 162environment(attr(ChickWeight, "outer")) <- emptyenv() 163