I am using tableNominal{reporttools}
to produce frequency tables. The way I understand it, tableNominal()
produces latex code which has to be copied and pasted onto a text file and then saved as .tex
. But is it possible to simple export the table produced as can be done in print(xtable(table), file="path/outfile.tex"))?
質問する
633 次
1 に答える
4
You may be able to use either latex
or latexTranslate
from the "Hmisc" package for this purpose. If you have the necessary program infrastructure the output gets sent to your TeX engine. (You may be able to improve the level of our answers by adding specific examples.)
Looks like that function does not return a character vector, so you need to use a strategy to capture the output from cat(). Using the example in the help page:
capture.output( TN <- tableNominal(vars = vars, weights = weights, group = group,
cap = "Table of nominal variables.", lab = "tab: nominal") ,
file="outfile.tex")
于 2012-08-03T07:42:14.423 に答える