-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
xtable: Changed print method? #17
Comments
Mark, Thanks for catching the change in print.xtable, and thanks for the I vaguely recall being backed into various undesirable kluges and For exporting to latex we decided to tap into xtable's functionality rather I also think we should keep our eyes open for new and newish R packages On Fri, Nov 30, 2012 at 8:52 PM, Mark Fredrickson
Ben Hansen |
Looking over the
xtable.xbal
method, it looks like we are trying to pass special markup options via attributes attached to the return value. These include putting in extra horizontal rows and multicolumn spanning headers that hold the strata names.In the current version of xtable, using attributes in this way has been replaced in favor of using global options.
Creating contingency tables in this way is a pretty nice feature. I'm working on creating tables for the new group tests, and we'll need these headers again. Also, it would be nice to have multiple row spanning blocks so that we can group variables in the "results" table (let alone some sort of unified table that shows both the variable-by-variable statistics and the group level tests).
Some options:
colnames(tab) <- c("Strata 1 \\ stat1", " \\ stat2", " \\ stat3", "Strata 2 \\ stat 1", "\\ stat2", "\\ stat3")
. We might still have to find some way of making sure xtable doesn't escape our markup.c("xbal_xtable", "xtable", "data.frame")
and implement our own print method that sets the appropriate options/arguments and callsprint.xtable
directly.include.rownames
andinclude.colunames
toFALSE
.Hmisc
package provides some latex stuff -- though it seems geared towards generating files rather than inline text generation.Of these, I think the custom
print
method is probably the best idea, but I'm certainly open to other solutions.The text was updated successfully, but these errors were encountered: