DanChaltiel / crosstable

Easy and thorough description of datasets
https://danchaltiel.github.io/crosstable/
112 stars 8 forks source link

table autofitting: documentation is wrong #57

Closed davidgohel closed 2 months ago

davidgohel commented 7 months ago

https://danchaltiel.github.io/crosstable/articles/crosstable-report.html#autofit-macro-for-large-tables

This is great, but large tables will unfortunately overflow your document.

This is a (known) limitation that cannot be fixed using R.

This is wrong, computed fields have nothing to do with your point. I find this curious, especially as the link doesn't take you to a theme related to tables and their dimensions at all.

Furthermore, the documentation of generate_autofit_macro() suggests that this functionality does not exist in flextable. I think it would be more clear for the user to say your function reproduce set_table_properties(layout = "autofit"). From our discussion https://github.com/davidgohel/flextable/pull/620#issuecomment-2028704187, I know you don't read the manuals, so I think it's better if I give you the correct names of functions.

DanChaltiel commented 7 months ago

Indeed, you are perfectly right. The link comes from a discussion I had with you in 2021 (https://github.com/davidgohel/officer/issues/347#issuecomment-762877543), but it seems I then completely mixed up between autofitting and references.

This is actually a very old vignette I started writing in 2020, before the features you mentioned. As it worked as intended, I never took the time to properly update it. My real job is to perform statistical analysis, so maintaining crosstable is more like a hobby that I can only attend when I have enough time.

I know you don't read the manuals

I am sensing that I have upset you and if this is the case I'm really sorry. However, this statement is plainly false and I read the manuals a lot, and the News when I update my packages (the one of flextable is not easily available in the web manuals BTW). But for packages like flextable and officer it is nearly impossible to remember everything because there is so much. I rely on search and the consistency of the interface.

Here, as with https://github.com/davidgohel/flextable/pull/620, the problem is functional duplication, where the autofitting feature is split between autofit() and set_table_properties() so the search can end up in 2 places at random. This kind of case makes it very difficult for the user to know which function to use, and leads annoying people like me to open issues like 620. If such feedback upsets you (as you closed 620), please accept my apologies and I'll buy you a beer at the next seminar :-).

TLDR: I will update the vignette asap

DanChaltiel commented 2 months ago

@davidgohel There you are, the vignette has been corrected. I plan on submitting to CRAN this month or in September. Now I'm sure I've upset you a lot, since it seems you have blocked me from watching and starring your repositories. Don't you think that's a bit of an overreaction?