I have ran a set regression in r and collected some of the statistics in a data frame format: variable|coefficient|s.e.|p-val|control|....| I am now writing that table using a template on my desktop saved as template.txt. When I write it in the following format it distorts the display so that values which should be displayed as [0.000] are displayed as [0]. Not a very critical problem but it messes up the aesthetic. Any way I can solve this?:

writetab(filename ="/Users/xx/Dropbox/project/tabfig/tables/overall_regs.tex", values = overall_regs, template="/Users/xx/Dropbox/project/templates/overall_regs.txt")

  • Without a minimal working example is hard to guess what are you doing exactly, and moreover we cannot reproduce the problem. Said, that, for instance, with digits in xtable you can control the decimals of each column in a table. There are many examples here, there and elsewhere.
    – Fran
    Mar 1, 2023 at 18:38
  • More specific example with regression table: tex.stackexchange.com/a/549338/11604
    – Fran
    Mar 2, 2023 at 9:34
  • thanks that really helps Mar 3, 2023 at 22:16


You must log in to answer this question.

Browse other questions tagged .