yihui / knitr

A general-purpose tool for dynamic report generation in R
https://yihui.org/knitr/
2.38k stars 876 forks source link

add native support for Emacs Org-mode tables #2258

Closed maxecharel closed 1 year ago

maxecharel commented 1 year ago

Hi, while you indicated that Pandoc was supporting Org-mode tables (https://github.com/yihui/knitr/issues/1372), I thought it would be nice to have native support in knitr. I therefore gave it a go :) No major changes/adjustment, I didn't want to mess with the well oiled mechanic of table.R ;)

kable(x = head(iris), format = "org", caption = "test")

#+CAPTION: test
| Sepal.Length| Sepal.Width| Petal.Length| Petal.Width|Species |
|-------------+------------+-------------+------------+--------|
|          5.1|         3.5|          1.4|         0.2|setosa  |
|          4.9|         3.0|          1.4|         0.2|setosa  |
|          4.7|         3.2|          1.3|         0.2|setosa  |
|          4.6|         3.1|          1.5|         0.2|setosa  |
|          5.0|         3.6|          1.4|         0.2|setosa  |
|          5.4|         3.9|          1.7|         0.4|setosa  |
CLAassistant commented 1 year ago

CLA assistant check
All committers have signed the CLA.

maxecharel commented 1 year ago

Hi @yihui , apologies for the delay in my response; I just see that you've accomplished quite a bit! Unfortunately I had to let my already very limited 'github activity' aside due to time allocation issues, but thank you for all your work :) I have signed the CLA ;)

yihui commented 1 year ago

No worries! Thank you anyway! I just happen to be allocating time mainly to Github projects recently :)