Contents

Using Emacs Org-Babel Mode to Write Literate Programming Documents

Introduction

We introduce the use of emacs org-babel model in this document. Emacs Org-Babel mode is a literate programming tool (aka. active document), which can embed multiple programming languages, inlcuding R, Python, C/C++ in one document. Babel has ability to execute source code within Org-mode documents.

Pre-reading

  1. Emacs/Getting Started Org-mode on Emacs

Source Code Insert & Running

Here is an format example:

1
2
#+BEGIN_SRC language
#+END_SRC

Reference List

  1. https://orgmode.org/worg/org-contrib/babel/languages/ob-doc-C.html
  2. https://orgmode.org/worg/org-contrib/babel/languages/ob-doc-R.html
  3. https://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html