Open slowkow opened 6 years ago
I found a workaround for this particular case:
ggvis() %>%
layer_ribbons(
data = subset(d, group == "A"),
x = ~time, y = ~low, y2 = ~high, fill := "pink"
) %>%
layer_paths(
data = subset(d, group == "A"),
x = ~time, y = ~median, stroke := "red"
) %>%
layer_ribbons(
data = subset(d, group == "B"),
x = ~time, y = ~low, y2 = ~high, fill := "skyblue"
) %>%
layer_paths(
data = subset(d, group == "B"),
x = ~time, y = ~median, stroke := "blue"
) %>%
layer_ribbons(
data = subset(d, group == "C"),
x = ~time, y = ~low, y2 = ~high, fill := "lightgreen"
) %>%
layer_paths(
data = subset(d, group == "C"),
x = ~time, y = ~median, stroke := "green"
)
I'm trying to show 3 lines, and each line should have a ribbon that shows the confidence interval.
The plot works OK without the ribbons:
Click here for my Session Info