Search code examples
remacsorg-mode

org mode not producing R plots


I am having problems with showing plots in my html output from org-mode file. Basically I learnt few months ago how to use org mode for this purpose, and I had a code like this:

#+begin_src R :file plot1.png :session :results graphics
 library(lattice)
 xyplot(1:10 ~ 1:10)
#+end_src

The code was working perfectly, and the file was created and printed when I exported to html file. Now the exact same code returns code block produced no output.; the file is created but not shown in the final html file. I already try several combinations after #+begin_src R but with no success. Did something change in the last updates of org-mode?. Or where is my problem?

Here is the initial part of my org file

#+LANGUAGE:   en
#+STYLE:      <style type="text/css">#outline-container-introduction{ clear:both; }</style>
#+BABEL: :exports both

Solution

  • I ran into a similar issue with code that was working and suddenly was not (probably because of upgrading org-mode). This discussion: https://www.mail-archive.com/[email protected]/msg125531.html led to me to discover that now you must list "file" among the ":results" options.