hierobrk(formula,data,maxlevels=10,mct=mean,lmd=NULL,umd=lmd,trueval=NA)
The user should take care when specifying different summary functions. hierobarp expects a measure of central tendency as the first function and measures of dispersion as the second and third, if "error bars" are to be displayed.
test.df<-data.frame(Age=rnorm(100,25,10),
Sex=sample(c("M","F"),100,TRUE),
Marital=sample(c("M","X","S","W"),100,TRUE),
Employ=sample(c("FT","PT","NO"),100,TRUE))
hierobrk(formula=Age~Sex+Marital+Employ,data=test.df)
Run the code above in your browser using DataLab