Open unDocUMeantIt opened 2 years ago
Did you get anywhere with this? I am having the same issue
no real solution yet. i tried to fix the resulting LaTeX file for a while, to get an idea what kableExtra
could generate. now i'm not sure this can be implemented cleanly using the multirow
package at all. workarounds that helped with one table were useless for others. i'd suggest to drop the use of multirow
completely and try with plain old empty table cells instead.
Can you please try the new row_group_label_position = "first"
?
Description
collapse_rows()
andkable_styling()
seem to function well for HTML output. but when they're used for LaTeX/PDF generation, you can quickly run into broken tables. i've noticed that it's next to impossible to callkable_styling()
beforecollapse_rows()
if you want the latter to have any effect, and that you can't use anylatex_hline
combined withcollapse_rows()
if you want the vertical alignment to be correct.A reproducible example
collapse_rows()
afterkable_styling()
It fails completely:
\newpage
collapse_rows()
beforekable_styling()
Almost works, but top alignment collapsed rows is off:
The odd allignment is due to the fact that
multirow
is being thrown off by extra space added between data rows by lines.\newpage
collapse_rows()
without hlineFixes top alignment:
Results