Sachinthaka Abeywardana
2013-Sep-10  12:27 UTC
[R] xtable Highlight the lowest and plus minus
I am using a similar dataset to the following:
a= c("Fruits", "Adam","errorA", "steve",
"errorS",
     "apples", 17.1,2.22, 3.2,1.1,
     "oranges", 3.1,2.55, 18.1,3.2 )
a_table=data.matrix(t(matrix(a,nrow=5)))
I would like to highlight the smallest value in the Adam and Steve columns
and, also plus and minus the errors *(using xtable/ hmisc)*
example output (ignoring decimals):
 Fruits && Adam && Steve \\
 Apples && 17\pm 2 && \mathbf{3 \pm 1} \\
 Oranges && \mathbf{3\pm 2} && 18 \pm 3\\
Additionally is there any way I can have just to 2 d.p.?
	[[alternative HTML version deleted]]
