Domanda

I am using pander to print nicer looking tables via RStudio, knitr, pander, pandoc, Word. I have a two-page table, to which I would like to add a Spanish caption:

set.caption("Límites izquierdo y derecho para las diferentes variables")
pander(LimitesUnivariado, include.rownames=FALSE)

This almost works, but my caption states:

Table: Límites izquierdo y derecho para las diferentes variables (continued below)

I can't find find the way to change the Table and continued below to their Spanish equivalents. Does anybody know how to do it?

È stato utile?

Soluzione

Thank you for reporting this issue on GitHub, I have just pushed a few lines to the master branch which introduced two new options to tweak the caption if the table was split. Quick example:

  1. Update the default caption of split tables without specified captions:

    > panderOptions('table.continues', 'Continuará')
    > pander(mtcars)
    
  2. Update affix concatenated to user specified caption if the table was split:

    > panderOptions('table.continues.affix', '(continuará)')
    > set.caption('MTCARS')
    > pander(mtcars)
    

Please install the most recent version of pander and verify if this update would work for you - and sorry for the above lame examples, please note that unfortunately I do not speak Spanish.

PS: I have not touched the Table: prefix as that seems to be specified in Pandoc's syntax which is to be removed by Pandoc automatically anyway when the conversion to some other document format is being done: please see the relevant docs. But if you would find a new options about this latter too, I would happily add that to the package in a jiffy.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top