我确信有一种更聪明,更优雅的方式来做我想做的事情。
我每年都会测量几次蜜蜂菌落参数。蜜蜂参数称为“total.adult.pop”,“total.reserves”,“worker.brood.surface”,“male.brood.surface”。这些数据存储在具有长格式的数据框中,其中列标识了殖民地,年份和测量周。
我想为每个殖民地计算每个测量周的每个蜜蜂参数的变化。
这是我的尝试:
在下一步中,我会再次将数据帧转换为长格式
HB_wide.all.years = data.frame() for(yr in years){ #子数据框只有1年的数据 HB.year = subset(HB,year == yr)
# Transform from long to wide format
library(reshape2)
HB.year_wide.adults = dcast(HB.year, year + numero + hive + ID_full ~ week , value.var = "total.adult.pop")
HB.year_wide.adults2 = HB.year_wide.adults
HB.year_wide.adults2$response = "total.adult.pop"
HB.year_wide.reserves = dcast(HB.year, year + numero + hive + ID_full ~ week , value.var = "total.reserves")
HB.year_wide.reserves2 = HB.year_wide.reserves
HB.year_wide.reserves2$response = "total.reserves"
HB.year_wide.worker.brood = dcast(HB.year, year + numero + hive + ID_full ~ week , value.var = "worker.brood.surface")
HB.year_wide.worker.brood2 = HB.year_wide.worker.brood
HB.year_wide.worker.brood2$response = "worker.brood.surface"
HB.year_wide.male.brood = dcast(HB.year, year + numero + hive + ID_full ~ week , value.var = "male.brood.surface")
HB.year_wide.male.brood2 = HB.year_wide.male.brood
HB.year_wide.male.brood2$response = "male.brood.surface"
# Combine the data frames of different honeybee data
HB.year_wide2 = rbind(HB.year_wide.adults2,HB.year_wide.reserves2,HB.year_wide.worker.brood2, HB.year_wide.male.brood2)
col.num = length(names(HB.year_wide2))
HB.year_wide2 = HB.year_wide2[,c(1,2,3,4,col.num,5:(col.num-1))]
cols = names(HB.year_wide2)
# Calculating the difference between two consecutive measurements
the difference in honeybee parameter between 2 measurements that followed each other
for(col in 7: length(cols)){
c1 = col-1
c2 = col
HB.year_wide3 = data.frame(HB.year_wide2,assign(paste0("change.from",cols[c1],"to",cols[c2]),
(HB.year_wide2[c2]-HB.year_wide2[c1])/ HB.year_wide2[c1]))
#! This step does not work! Assign creates a data frame of one column. However, the binding to HB.year_wide2 does not work.
}
# Combining data frames of all years
HB.year_wide3$year = yr
HB_wide.all.years = merge(HB_wide.all.years, HB.year_wide3, all = T)}
为什么我不能将新创建的“列”(由assign创建的数据帧)绑定到现有数据框? 我很高兴听到是否存在(完全)不同的方式,以及我通常如何创建一个包含存储在不同行中的值计算结果的列。谢谢!
PS:每次测量时都没有测量到一些菌落。跳过测量时我不想要值。例如,如果在第1个,第2个,第4个测量周测量菌落,而不是在第3个测量周,那么我想仅计算1和2之间的变化。不是2和4.编辑:很抱歉没有提供一些数据。这是数据框的子集。
structure(list(year = c(2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L, 2012L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L,
2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L, 2013L
), numero = c(25L, 25L, 25L, 25L, 25L, 25L, 25L, 25L, 25L, 25L,
25L, 25L, 25L, 25L, 25L, 25L, 25L, 25L, 25L, 25L, 25L, 25L, 25L,
25L, 25L, 25L, 25L, 25L, 25L, 25L, 25L, 25L, 29L, 29L, 29L, 29L,
29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L,
29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L,
29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L, 29L,
39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L,
39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L, 39L,
39L, 39L, 39L, 39L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
4L, 4L, 4L, 4L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L,
8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L,
8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 18L, 18L, 18L, 18L,
18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L,
18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L,
18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L, 18L,
18L, 18L, 18L, 18L), hive = structure(c(29L, 29L, 91L, 91L, 91L,
91L, 91L, 91L, 91L, 91L, 91L, 119L, 119L, 119L, 119L, 119L, 119L,
119L, 119L, 119L, 119L, 119L, 119L, 133L, 133L, 133L, 133L, 133L,
133L, 133L, 133L, 133L, 122L, 122L, 122L, 122L, 122L, 122L, 122L,
122L, 122L, 122L, 122L, 122L, 123L, 123L, 123L, 123L, 123L, 131L,
131L, 131L, 131L, 131L, 131L, 131L, 131L, 131L, 131L, 131L, 131L,
131L, 131L, 143L, 143L, 143L, 143L, 143L, 143L, 143L, 143L, 143L,
143L, 143L, 143L, 68L, 68L, 68L, 68L, 73L, 73L, 73L, 73L, 73L,
73L, 73L, 73L, 92L, 92L, 92L, 92L, 92L, 92L, 94L, 94L, 94L, 94L,
94L, 103L, 103L, 103L, 103L, 112L, 112L, 114L, 58L, 102L, 102L,
102L, 102L, 102L, 102L, 102L, 102L, 102L, 102L, 102L, 102L, 102L,
102L, 105L, 131L, 131L, 131L, 131L, 131L, 131L, 131L, 131L, 131L,
131L, 131L, 131L, 131L, 131L, 131L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 84L, 84L, 84L, 84L, 84L, 84L,
84L, 84L, 84L, 85L, 85L, 85L, 98L, 98L, 98L, 98L, 98L, 98L, 98L,
98L, 98L, 98L, 98L, 98L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
1L, 1L, 1L, 1L, 1L, 1L, 18L, 18L, 18L, 18L, 81L, 81L, 81L, 81L,
81L, 100L, 100L, 100L, 100L, 100L, 100L, 100L, 100L, 100L, 100L,
100L, 100L, 107L, 107L, 107L, 107L, 107L, 107L, 107L, 107L, 107L,
107L, 107L), .Label = c("1", "10", "108", "11", "111", "116",
"12", "13", "14", "141", "142", "143", "144", "145", "146", "147",
"149", "15", "150", "151", "152", "153", "154", "155", "156",
"157", "158", "159", "16", "160", "161", "162", "163", "165",
"168", "169", "17", "170", "171", "172", "173", "174", "175",
"176", "177", "178", "179", "18", "180", "181", "182", "1838",
"184", "185", "186", "187", "188", "19", "190", "193", "194",
"195", "196", "197", "198", "1984", "199", "2", "20", "200",
"202", "21", "22", "23", "231", "24", "25", "26", "27", "28",
"29", "3", "30", "31", "32", "33", "34", "341", "35", "36", "37",
"38", "3818", "39", "4", "40", "41", "42", "43", "44", "444",
"45", "46", "461", "47", "48", "49", "5", "50", "51", "52", "53",
"54", "55", "56", "57", "58", "586", "59", "6", "60", "61", "62",
"620", "63", "64", "65", "66", "67", "68", "69", "7", "70", "72",
"74", "76", "761", "77", "8", "81", "877", "89", "9", "99", "r52",
"r53", "r54", "r55", "r56", "r57", "r58", "r59", "r61", "r62",
"r63", "r64", "r67", "r68", "r69", "r70", "r97", "0"), class = "factor"),
week = c(27L, 39L, 13L, 15L, 23L, 25L, 27L, 29L, 31L, 37L,
39L, 13L, 15L, 18L, 23L, 25L, 27L, 29L, 31L, 33L, 35L, 37L,
39L, 13L, 15L, 18L, 27L, 29L, 31L, 33L, 35L, 39L, 13L, 15L,
18L, 19L, 21L, 23L, 25L, 27L, 29L, 31L, 33L, 35L, 13L, 21L,
23L, 37L, 39L, 13L, 15L, 18L, 19L, 21L, 23L, 25L, 27L, 29L,
31L, 33L, 35L, 37L, 39L, 13L, 15L, 18L, 19L, 25L, 27L, 29L,
31L, 33L, 35L, 37L, 39L, 13L, 15L, 18L, 37L, 13L, 15L, 18L,
19L, 25L, 31L, 35L, 39L, 13L, 15L, 18L, 23L, 25L, 27L, 31L,
33L, 35L, 37L, 39L, 31L, 33L, 35L, 39L, 37L, 39L, 13L, 44L,
18L, 20L, 22L, 24L, 26L, 28L, 30L, 32L, 34L, 36L, 38L, 40L,
42L, 44L, 44L, 16L, 18L, 20L, 22L, 24L, 26L, 28L, 30L, 32L,
34L, 36L, 38L, 40L, 42L, 44L, 16L, 18L, 20L, 22L, 24L, 26L,
28L, 30L, 32L, 34L, 36L, 38L, 40L, 42L, 44L, 16L, 30L, 32L,
34L, 36L, 38L, 40L, 42L, 44L, 16L, 22L, 44L, 16L, 18L, 20L,
26L, 28L, 30L, 32L, 34L, 36L, 38L, 40L, 42L, 16L, 18L, 20L,
22L, 24L, 26L, 28L, 30L, 32L, 34L, 36L, 38L, 40L, 42L, 44L,
16L, 18L, 20L, 44L, 16L, 18L, 24L, 26L, 44L, 16L, 20L, 22L,
28L, 30L, 32L, 34L, 36L, 38L, 40L, 42L, 44L, 16L, 24L, 26L,
28L, 32L, 34L, 36L, 38L, 40L, 42L, 44L), ID_full = c("16_2012_a",
"16_2012_a", "37_2012_a", "37_2012_a", "37_2012_a", "37_2012_a",
"37_2012_a", "37_2012_a", "37_2012_a", "37_2012_a", "37_2012_a",
"59_2012_a", "59_2012_a", "59_2012_a", "59_2012_a", "59_2012_a",
"59_2012_a", "59_2012_a", "59_2012_a", "59_2012_a", "59_2012_a",
"59_2012_a", "59_2012_a", "70_2012_a", "70_2012_a", "70_2012_a",
"70_2012_a", "70_2012_a", "70_2012_a", "70_2012_a", "70_2012_a",
"70_2012_a", "61_2012_a", "61_2012_a", "61_2012_a", "61_2012_a",
"61_2012_a", "61_2012_a", "61_2012_a", "61_2012_a", "61_2012_a",
"61_2012_a", "61_2012_a", "61_2012_a", "62_2012_a", "62_2012_a",
"62_2012_a", "62_2012_a", "62_2012_a", "69_2012_a", "69_2012_a",
"69_2012_a", "69_2012_a", "69_2012_a", "69_2012_a", "69_2012_a",
"69_2012_a", "69_2012_a", "69_2012_a", "69_2012_a", "69_2012_a",
"69_2012_a", "69_2012_a", "9_2012_a", "9_2012_a", "9_2012_a",
"9_2012_a", "9_2012_a", "9_2012_a", "9_2012_a", "9_2012_a",
"9_2012_a", "9_2012_a", "9_2012_a", "9_2012_a", "2_2012_a",
"2_2012_a", "2_2012_a", "2_2012_a", "22_2012_a", "22_2012_a",
"22_2012_a", "22_2012_a", "22_2012_a", "22_2012_a", "22_2012_a",
"22_2012_a", "38_2012_a", "38_2012_a", "38_2012_a", "38_2012_a",
"38_2012_a", "38_2012_a", "39_2012_a", "39_2012_a", "39_2012_a",
"39_2012_a", "39_2012_a", "46_2012_a", "46_2012_a", "46_2012_a",
"46_2012_a", "53_2012_a", "53_2012_a", "55_2012_a", "19_2013_a",
"45_2013_a", "45_2013_a", "45_2013_a", "45_2013_a", "45_2013_a",
"45_2013_a", "45_2013_a", "45_2013_a", "45_2013_a", "45_2013_a",
"45_2013_a", "45_2013_a", "45_2013_a", "45_2013_a", "47_2013_a",
"69_2013_a", "69_2013_a", "69_2013_a", "69_2013_a", "69_2013_a",
"69_2013_a", "69_2013_a", "69_2013_a", "69_2013_a", "69_2013_a",
"69_2013_a", "69_2013_a", "69_2013_a", "69_2013_a", "69_2013_a",
"11_2013_a", "11_2013_a", "11_2013_a", "11_2013_a", "11_2013_a",
"11_2013_a", "11_2013_a", "11_2013_a", "11_2013_a", "11_2013_a",
"11_2013_a", "11_2013_a", "11_2013_a", "11_2013_a", "11_2013_a",
"31_2013_a", "31_2013_a", "31_2013_a", "31_2013_a", "31_2013_a",
"31_2013_a", "31_2013_a", "31_2013_a", "31_2013_a", "32_2013_a",
"32_2013_a", "32_2013_a", "42_2013_a", "42_2013_a", "42_2013_a",
"42_2013_a", "42_2013_a", "42_2013_a", "42_2013_a", "42_2013_a",
"42_2013_a", "42_2013_a", "42_2013_a", "42_2013_a", "1_2013_a",
"1_2013_a", "1_2013_a", "1_2013_a", "1_2013_a", "1_2013_a",
"1_2013_a", "1_2013_a", "1_2013_a", "1_2013_a", "1_2013_a",
"1_2013_a", "1_2013_a", "1_2013_a", "1_2013_a", "15_2013_a",
"15_2013_a", "15_2013_a", "15_2013_a", "29_2013_a", "29_2013_a",
"29_2013_a", "29_2013_a", "29_2013_a", "44_2013_a", "44_2013_a",
"44_2013_a", "44_2013_a", "44_2013_a", "44_2013_a", "44_2013_a",
"44_2013_a", "44_2013_a", "44_2013_a", "44_2013_a", "44_2013_a",
"49_2013_a", "49_2013_a", "49_2013_a", "49_2013_a", "49_2013_a",
"49_2013_a", "49_2013_a", "49_2013_a", "49_2013_a", "49_2013_a",
"49_2013_a"), total.adult.pop = c(2.23, 0.3, 2.27, 1.96,
1.79, 1.05, 1.32, 1.85, 1.19, 1.08, 1.32, 3.08, 3.14, 4.83,
1.53, 2.75, 2.09, 3.29, 3.06, 3.47, 3.03, 2.72, 1.32, 1.48,
1.43, 4.62, 1.06, 2.27, 2.08, 3.06, 2.29, 1.23, 1.12, 0.97,
2.13, 2.31, 2.03, 3.05, 2.8, 3.14, 3.21, 2.13, 2.1, 1.16,
0.54, 1.69, 1.99, 0.61, 0.68, 1.62, 2.38, 2.32, 2.2995, 2.29,
3.64, 2.95, 3.22, 3, 2.21, 2.04, 1.8, 1.62, 1.49, 2.4, 2.2,
3.89, 3.55, 1.08, 1.31, 2.16, 2.45, 2.46, 1.93, 1.55, 1.11,
2.14, 2.95, 1.84, 0.78, 1.38, 1.12, 1.44, 1.44, 1.74, 1.67,
1.26, 1.18, 1.61, 1.95, 1.98, 0.5, 0.95, 0.93, 1.09, 0.9,
1.64, 1.93, 1.53, 1.95, 1.17, 1.54, 1.41, 0.16, 0.23, 2.3,
1.4, 1.75, 1.32, 1.92, 1.75, 1.44, 0.97, 0.81, 0.79, 0.55,
0.44, 0.63, 0.64, 0.66, 0.81, 1.61, 1.91, 0.99, 2.61, 3.86,
3.7, 3.1, 2.42, 1.41, 1.03, 0.98, 1.22, 1.22, 1.1, 0.82,
0.75, 2.11, 2.595, 3.12, 3.48, 3.18, 2.92, 2.38, 2.42, 1.98,
1.38, 1.02, 0.8, 0.79, 0.69, 0.8, 1.55, 1.61, 1.585, 1.82,
1.64, 1.36, 1.55, 1.7, 1.54, 1.025, 3.33, 0.99, 1.77, 1.76,
2.98, 0.95, 1.1, 1.13, 0.79, 0.86, 1.08, 1.01, 1.13, 1.1,
1.91, 2.12, 2.82, 3.54, 3.34, 3.33, 2.11, 1.94, 1.78, 1.35,
0.61, 0.77, 0.53, 0.84, 1, 1.42, 3.25, 3.37, 1.21, 1.81,
1.78, 1.94, 1.2, 1.32, 2.15, 3.31, 3.22, 2.53, 2.3, 2.76,
2.37, 2.54, 2.14, 2.14, 1.88, 1.91, 2.13, 1.1, 1.06, 1.78,
1.29, 0.91, 1.23, 1.09, 0.84, 1.01, 1.12), total.reserves = c(8.19,
21.36, 4.17, 5.08, 12.78, 11.55, 9.1, 13.73, 28.77, 16.23,
13.91, 8.88, 7.14, 5.95, 10.08, 6.6, 6.14, 16.98, 45.11,
48.98, 10.4, 11.69, 11.47, 2.85, 3.41, 2.13, 7.38, 11.5,
30.97, 30.07, 14.16, 13.98, 2.77, 1.42, 6.42, 7.48, 13.72,
6.48, 4.61, 4.67, 12.62, 26.23, 28.88, 13.97, 16.56, 35.55,
15.89, 21.47, 20.12, 4.07, 1.47, 5.29, 7.91, 15.75, 3.76,
3.93, 4.69, 17.14, 30.24, 38.21, 17.68, 15.86, 13.9, 9.43,
5.93, 11.86, 16.61, 10.93, 8.8, 9.89, 17.95, 21.52, 18.28,
16.96, 16.27, 9.11, 8.15, 12.38, 10.41, 3.59, 2.34, 0.46,
1.3, 3.49, 12.27, 12.08, 9.43, 4.38, 4.11, 4.11, 12.44, 9.81,
7.33, 15.7, 15.38, 12.54, 11.13, 10.82, 29.71, 28.8, 16.19,
15.37, 17.46, 16.32, 4.29, 24.6, 5.69, 6.45, 4.3, 3.76, 0.61,
0.72, 2.42, 5.57, 4.32, 4.55, 4.03, 6.04, 5.39, 5.15, 9.12,
1.54, 6.53, 5.33, 3.76, 4.01, 1.3, 2.18, 6.27, 8.97, 8.58,
9.89, 9.04, 9.2, 8.86, 8.01, 1.82, 10.2, 14.69, 12.25, 9.34,
6.02, 3.64, 10.67, 17.49, 15.28, 13.75, 12.57, 8.32, 5.69,
5.18, 1.69, 12.8, 18.48, 15.88, 15.68, 14.5, 10.25, 9.55,
9.38, 1.5, 4.38, 22.16, 1.11, 4.88, 7.52, 5.1, 3.33, 3.03,
2.63, 0.86, 1.6, 1.25, 4.17, 3.75, 1.04, 5.76, 7.78, 5.6,
1.5, 2.07, 2.73, 8.73, 18.19, 17.18, 13.62, 13.01, 9.66,
9.28, 7.39, 0.89, 8.17, 11.33, 6.98, 1.15, 4.83, 7.93, 5.82,
14.96, 2.45, 6.22, 3.54, 2.13, 14.95, 25.85, 27.31, 17.61,
15.83, 14.02, 13.11, 11.82, 2.55, 3.79, 1.84, 3.45, 15.13,
14.36, 14.45, 13.24, 11.88, 11.12, 9.99), worker.brood.surface = c(5611.683,
0, 4699.0482, 8942.5644, 2186.5536, 4145.3412, 5933.697,
5136.516, 4358.1846, 2624.8068, 3044.2104, 6061.7172, 9455.4306,
8333.8794, 3664.6764, 7843.0044, 10047.6222, 8539.6542, 7360.7688,
0, 5323.4412, 2381.3328, 2318.5008, 3394.4988, 8067.6288,
8088.8346, 4609.5126, 5941.551, 6223.5096, 6855.7566, 4907.9646,
1288.8414, 3019.0776, 5566.9152, 4311.0606, 4926.8142, 7642.7274,
8199.576, 7537.4838, 7719.6966, 8255.3394, 5243.3304, 5521.362,
4633.86, 1129.4052, 5702.7894, 7506.8532, 1568.4438, 1573.1562,
3828.825, 7517.8488, 6294.981, 5881.8606, 8400.6384, 8718.7254,
9228.45, 8894.655, 7325.4258, 4975.509, 4693.5504, 4343.262,
3473.0388, 2503.8552, 6414.3618, 10378.2756, 8391.999, 9347.8308,
3409.4214, 6585.579, 7795.095, 6505.4682, 4143.7704, 2354.6292,
1178.8854, 544.2822, 5395.698, 9089.4342, 7703.9886, 2854.929,
4190.8944, 7655.2938, 1427.8572, 3318.315, 4035.3852, 1968.9978,
1463.2002, 2042.8254, 4430.4414, 8468.9682, 7011.2658, 3100.7592,
3364.6536, 4698.2628, 2288.6556, 3930.1416, 3361.512, 3006.5112,
1544.8818, 4280.43, 4862.4114, 5947.0488, 2058.5334, 811.3182,
1167.1044, 2413.5342, 401.3394, 4516.8354, 5275.5318, 5758.5528,
4733.6058, 3768.3492, 7007.3388, 4034.5998, 2226.609, 2088.3786,
2214.828, 1584.1518, 1606.143, 1312.4034, 264.6798, 976.2522,
845.8758, 7455.0168, 8199.576, 8844.3894, 7584.6078, 6268.2774,
5557.4904, 4417.0896, 3725.1522, 3838.2498, 3079.5534, 2375.0496,
2104.872, 1816.6302, 459.459, 4061.3034, 6203.0892, 4868.6946,
5837.0928, 4597.7316, 5024.2038, 5865.3672, 4085.6508, 3180.0846,
2923.2588, 2531.3442, 1554.3066, 1646.1984, 1621.0656, 1123.9074,
1822.9134, 5051.6928, 3943.4934, 3665.4618, 3634.0458, 2960.958,
3018.2922, 2569.0434, 1337.5362, 1698.8202, 6672.7584, 1491.4746,
1318.6866, 6950.79, 6826.6968, 2149.6398, 4574.1696, 3715.7274,
4186.9674, 3544.5102, 2613.0258, 1450.6338, 1705.1034, 2092.3056,
1519.749, 5270.034, 6975.9228, 8249.8416, 6898.1682, 2142.5712,
6034.2282, 4673.9154, 1926.5862, 1029.6594, 2141.0004, 1347.7464,
2355.4146, 2683.7118, 2289.441, 1360.3128, 5094.1044, 6496.0434,
1849.617, 1794.639, 6493.6872, 768.9066, 2130.7902, 1097.2038,
1373.6646, 5597.5458, 5588.121, 7333.2798, 5120.0226, 3560.2182,
4026.7458, 4058.1618, 1709.8158, 2151.996, 2826.6546, 871.794,
1564.5168, 2195.193, 4561.6032, 5734.2054, 457.1028, 3301.8216,
2916.1902, 2631.09, 2639.7294, 2672.7162, 1389.3726), male.brood.surface = c(468.8838,
0, 3.1416, 362.0694, 111.5268, 65.1882, 109.956, 102.102,
65.9736, 0, 0, 224.6244, 926.772, 868.6524, 113.0976, 234.0492,
267.036, 335.3658, 227.766, 0, 0, 0, 0, 14.1372, 333.0096,
424.116, 0, 251.328, 201.0624, 175.1442, 0, 0, 146.0844,
562.3464, 428.043, 408.408, 784.6146, 501.8706, 63.6174,
325.941, 182.9982, 0, 0, 0, 0, 262.3236, 347.9322, 0, 0,
391.9146, 1382.304, 336.1512, 1299.837, 1985.4912, 1274.7042,
158.6508, 1406.6514, 586.6938, 333.795, 322.7994, 63.6174,
0, 0, 109.956, 581.196, 183.7836, 316.5162, 0, 0, 3.927,
0, 0, 0, 0, 0, 91.1064, 636.174, 334.5804, 0, 0, 159.4362,
0, 0, 31.416, 0, 0, 0, 0, 200.277, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 312.5892, 0, 958.188, 1039.8696, 742.203,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1317.9012, 1372.8792,
1375.2354, 488.5188, 100.5312, 147.6552, 0, 0, 0, 0, 0, 0,
0, 0, 496.3728, 1522.1052, 1229.9364, 991.9602, 938.553,
664.4484, 797.181, 231.693, 7.0686, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 27.489, 519.9348, 0, 0, 1101.1308,
849.8028, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 735.9198, 801.108,
959.7588, 422.5452, 274.89, 270.963, 0, 0, 0, 0, 0, 0, 0,
0, 307.8768, 1981.5642, 2379.762, 0, 28.2744, 1114.4826,
0, 0, 0, 296.0958, 958.9734, 1099.56, 214.4142, 409.9788,
122.5224, 36.1284, 0, 0, 0, 0, 0, 0, 0, 0, 183.7836, 0, 0,
0, 0, 0, 0, 0)), .Names = c("year", "numero", "hive", "week",
"ID_full", "total.adult.pop", "total.reserves", "worker.brood.surface",
"male.brood.surface"), row.names = 1470:1691, class = "data.frame")