leifeld / texreg

Conversion of R Regression Output to LaTeX or HTML Tables
110 stars 42 forks source link

Texreg full text width #205

Closed shartmann1102 closed 10 months ago

shartmann1102 commented 1 year ago

Hi Philip,

I am using the texreg function, which has helped me a lot to quickly build Latex tables for my thesis.

However, I am wondering if there is a possibility to adjust the width of the tables to the full-text width? Apparently, this is possible with packages such as the tabularx package. I understand from some previous posts that a table can be generated as a tabular if longtable and column are set to FALSE. Unfortunately, I am still not following on how to change it to a working tabularx table with full width as well as preferably a long-table format?

Many thanks for your help and time in advance.

Best regards, Sven

leifeld commented 1 year ago

Hi Sven,

tabularx is currently not supported. But if you'd like to start a pull request and add support to the texreg function, I'm happy to review it and consider it as an addition to the package. I don't think it should be very complicated.

If you're fine with a somewhat hacky solution, you can use the table argument to strip the output down to the tabular environment and omit the table float, then manipulate the resulting string output further. But it's not ideal.

Best, Philip