Description Usage Arguments Value Examples
Utility to provide Lower and Upper Limit values for Error Bars.
1 | ErrorBar_LL_UL(x, type = "SD", CI = 0.95)
|
x |
- the data |
type |
- either SD, SE, or CI |
CI |
- confidence interval, defaults to 95% |
results with ymin and ymax
1 2 3 4 5 6 7 8 9 10 11 12 | ## Not run:
library(ggplot)
p<-ggplot(data=plot.data,aes(x=measured.value,y=outcome))
p<-p+geom_point(size=2,col='blue')
p<-p+stat_summary(fun.y='mean', geom="point", size = 5, shape=15,col='red')
This style is from the old ggplot v1 code
p<-p+stat_summary(fun.data = 'ErrorBar_LL_UL',type='CI',CI=0.95, geom = "errorbar", width = 10)
This style is from the newer ggplot v2 code ... hopefully you are at this level or above
p<-p+stat_summary(fun.data = 'ErrorBar_LL_UL',fun.args=list(type='CI',CI=0.95), geom = "errorbar", width = 10)
p
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.