I have an org file with R code in it. When I attempt to export to html or pdf I get an error:

For example if my file was:

#+begin_src R :exports code
square <- function(x) 
 x * x


I type: C-c C-e h o the mini buffer says: Symbol’s value as variable is void: backend

  • And if you change the language to something other then R it works? – Prgrm.celeritas Mar 19 '19 at 21:34
  • yes emacs lisp works for example – user27815 Mar 19 '19 at 21:59
  • What major mode are you using for R? – Prgrm.celeritas Mar 19 '19 at 22:50

I already had this line in my .emacs but I added another copy at the end of the .emacs file and it solved the problem. So maybe there is an ordering constraint for this to work correctly.

(require 'ess-site)

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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