r - Chunk in knitr fails to compile in latex; shaded rows of xtable -
this chunk in knitr. fails compile in latex, although chunk runs , gives me table (perhaps naievely) looks ok?
<<results_a549_rate, results='asis', echo=false>>= library(xtable) end_table<-matrix(rnorm(20), nrow=5) rws<-seq(from=1, to=dim(end_table)[1], by=2) cols<-rep(c("\\rowcolor[gray]{0.95}"), length(rws)) x_endtable<-xtable(end_table, caption="rate changes", digits=3, label="table_a549") print(x_endtable, booktabs=true, add.to.row=list(pos=as.list(rws), command=cols)) @
Comments
Post a Comment