metrumresearchgroup / yspec

Data Specification for Pharmacometrics
https://metrumresearchgroup.github.io/yspec
5 stars 2 forks source link

output_format = "word_document" #154

Open oskarrgh opened 2 weeks ago

oskarrgh commented 2 weeks ago

ys_document() allows passing output_format = "word_document" to render_define() to get a define file in docx file format. However, the table are not rendered as expected, or at all. This issue has been discussed here https://stackoverflow.com/questions/73296439/r-markdown-does-not-covert-tex-table-to-word-document-while-it-works-fine-in-p and solution is to include a lua file and point to it in the define.Rmd file. Implementing this I have gotten it to output a table in the docx define file but the document and table formating is not super pretty. Is rendering of docx output file something you would consider adding as a possible feature?

kylebaron commented 1 week ago

Hi @oskarrgh -

Yes, I think we should be able to render a better define.docx file directly. This would take some time to develop and release. In the meantime, let me look into some (existing) code we could work with to get the equivalent result.

Kyle

kylebaron commented 1 week ago

Here's something to get started; it's pretty simple but all I could do before starting the day.

define-docx.zip