我有以下数据:
structure(list(Expo = structure(c(2L, 2L, 2L, 2L, 2L, 2L, 2L,
2L, 2L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
2L), .Label = c("DC", "DI"), class = "factor"), Quail = c(5L,
6L, 16L, 17L, 28L, 29L, 30L, 53L, 54L, 11L, 12L, 46L, 48L, 60L,
11L, 48L, 6L, 5L, 6L, 18L, 29L, 30L, 53L, 11L, 36L, 46L, 47L,
60L, 11L, 4L, 5L, 6L, 16L, 17L, 28L, 29L, 30L, 52L, 53L, 54L),
Segment = c(2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L), Position = c(1949L,
1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L,
1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L,
1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L,
1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L, 1949L,
1949L, 1949L, 1949L), Freq = c(0.034496, 0.034845, 0.031079,
0.020761, 0.037311, 0.047204, 0.062257, 0.100617, 0.022637,
0.587758, 0.470607, 0.037855, 0.02897, 0.034457, 0.87815,
0.022788, 0.169897, 0.058831, 0.116039, 0.032077, 0.081132,
0.09126, 0.051852, 0.896703, 0.09873, 0.054908, 0.027505,
0.50293, 0.975181, 0.03713, 0.092243, 0.028103, 0.044125,
0.057707, 0.091152, 0.085498, 0.130286, 0.030099, 0.049717,
0.070069), day = c(3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L,
3L, 3L, 3L, 3L, 7L, 7L, 7L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L,
5L, 1L, 1L, 8L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L
)), row.names = c(NA, -40L), class = "data.frame")
当我跑
ggplot(Expo.Shared.PB1, aes(x=as.numeric(day), y=Freq, color = as.character(Quail))) +
geom_path()+
geom_point() +
facet_grid(Expo~.)
它给了我以下(不正确的)情节。
我解决了将 stat="summary" 添加到两个 geoms 的问题,但这样做会给我以下消息:没有提供汇总函数,默认为 `mean_se()
ggplot(Expo.Shared.PB1, aes(x=as.numeric(day), y=Freq, color = as.character(Quail))) +
geom_path(stat = "summary")+
geom_point(stat = "summary") +
facet_grid(Expo~.)
输出:
情节似乎是我正在寻找的,现在:
stat="summary" 到底在做什么?绘制的值是否从原始值修改?可以忽略消息吗?(我确定不是)。