2

In org-mode:

#+BEGIN_SRC calc :var x=5 :var y=2
2+a*x**y
#+END_SRC

returns

No org-babel-execute function for calc!

How do I enable calc for org-babel-execute?

2 Answers 2

8

As described in org documentation:

By default, only 'emacs-lisp' is enabled for evaluation. To enable or disable other languages, customize the 'org-babel-load-languages' variable either through the Emacs customization interface, or by adding code to the init file as shown next:

In this example, evaluation is disabled for 'emacs-lisp', and enabled for `R'.

(org-babel-do-load-languages
  'org-babel-load-languages
  '((emacs-lisp . nil)
    (R . t)))

So here you could do the following:

(org-babel-do-load-languages
   'org-babel-load-languages
      '((calc . t)))
0

To add to JeanPierre's answer, you can run M-x customize-variable with org-babel-load-languages to modify the list from Emacs.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.