* Generating plot with org-babel-R
@ 2012-02-04 22:52 Riccardo Romoli
2012-02-04 23:37 ` Thomas S. Dye
0 siblings, 1 reply; 17+ messages in thread
From: Riccardo Romoli @ 2012-02-04 22:52 UTC (permalink / raw
To: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 849 bytes --]
Hi, I'm trying to generate some figure with R, into an org session. Firstly
I use the code in the org site. The problem is that the code do not
generate any figure.
This is the code:
#+TITLE:Test
#+AUTHOR: Your Name
#+EMAIL: your-email@server.com
#+BABEL: :session *R* :cache yes :results output graphics :exports
both :tangle yes
* Example of Org-Babel for R Literate Programming
** R text output
A simple summary.
#+begin_src R
x <- rnorm(10)
summary(x)
#+end_src
** R graphics output
Note we use the object =x= generated in previous code block, thanks to
the header option =:session *R*=. The output graphics file is
=a.png=.
#+begin_src R :file a.png
y <- rnorm(10)
plot(x, y)
#+end_src
Same plot with larger dimension:
#+begin_src R :file b.png :width 800 :height 800
plot(x, y)
#+end_src
Where do I wrong?
Best
Riccardo
[-- Attachment #2: Type: text/html, Size: 963 bytes --]
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Generating plot with org-babel-R
2012-02-04 22:52 Generating plot with org-babel-R Riccardo Romoli
@ 2012-02-04 23:37 ` Thomas S. Dye
2012-02-05 11:08 ` Riccardo Romoli
0 siblings, 1 reply; 17+ messages in thread
From: Thomas S. Dye @ 2012-02-04 23:37 UTC (permalink / raw
To: Riccardo Romoli; +Cc: emacs-orgmode
Hi Riccardo,
This code appears to be outdated. I don't recall this code on the org
site. Could you send a URL?
All the best,
Tom
Riccardo Romoli <ric.romoli@gmail.com> writes:
> Hi, I'm trying to generate some figure with R, into an org session. Firstly
> I use the code in the org site. The problem is that the code do not
> generate any figure.
>
> This is the code:
>
> #+TITLE:Test
> #+AUTHOR: Your Name
> #+EMAIL: your-email@server.com
> #+BABEL: :session *R* :cache yes :results output graphics :exports
> both :tangle yes
>
> * Example of Org-Babel for R Literate Programming
> ** R text output
> A simple summary.
> #+begin_src R
> x <- rnorm(10)
> summary(x)
> #+end_src
>
> ** R graphics output
> Note we use the object =x= generated in previous code block, thanks to
> the header option =:session *R*=. The output graphics file is
> =a.png=.
>
> #+begin_src R :file a.png
> y <- rnorm(10)
> plot(x, y)
> #+end_src
>
> Same plot with larger dimension:
>
> #+begin_src R :file b.png :width 800 :height 800
> plot(x, y)
> #+end_src
>
>
> Where do I wrong?
>
> Best
> Riccardo
> Hi, I'm trying to generate some figure with R, into an org session. Firstly I use the code in the org site. The problem is that the code do not generate any figure. This is the code:
> #+TITLE:Test
> #+AUTHOR: Your Name
> #+EMAIL: mailto:your-email@server.com
> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>
> * Example of Org-Babel for R Literate Programming
> ** R text output
> A simple summary.
> #+begin_src R
> x <- rnorm(10)
> summary(x)
> #+end_src
>
> ** R graphics output
> Note we use the object =x= generated in previous code block, thanks to
> the header option =:session *R*=. The output graphics file is
> =a.png=.
>
> #+begin_src R :file a.png
> y <- rnorm(10)
> plot(x, y)
> #+end_src
>
> Same plot with larger dimension:
>
> #+begin_src R :file b.png :width 800 :height 800
> plot(x, y)
> #+end_src
> Where do I wrong?BestRiccardo
--
Thomas S. Dye
http://www.tsdye.com
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Generating plot with org-babel-R
2012-02-04 23:37 ` Thomas S. Dye
@ 2012-02-05 11:08 ` Riccardo Romoli
2012-02-05 16:45 ` Thomas S. Dye
0 siblings, 1 reply; 17+ messages in thread
From: Riccardo Romoli @ 2012-02-05 11:08 UTC (permalink / raw
To: Thomas S. Dye; +Cc: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 2370 bytes --]
Hi, this is the URL:
http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
Best
R
2012/2/5 Thomas S. Dye <tsd@tsdye.com>
> Hi Riccardo,
>
> This code appears to be outdated. I don't recall this code on the org
> site. Could you send a URL?
>
> All the best,
> Tom
>
> Riccardo Romoli <ric.romoli@gmail.com> writes:
>
> > Hi, I'm trying to generate some figure with R, into an org session.
> Firstly
> > I use the code in the org site. The problem is that the code do not
> > generate any figure.
> >
> > This is the code:
> >
> > #+TITLE:Test
> > #+AUTHOR: Your Name
> > #+EMAIL: your-email@server.com
> > #+BABEL: :session *R* :cache yes :results output graphics :exports
> > both :tangle yes
> >
> > * Example of Org-Babel for R Literate Programming
> > ** R text output
> > A simple summary.
> > #+begin_src R
> > x <- rnorm(10)
> > summary(x)
> > #+end_src
> >
> > ** R graphics output
> > Note we use the object =x= generated in previous code block, thanks to
> > the header option =:session *R*=. The output graphics file is
> > =a.png=.
> >
> > #+begin_src R :file a.png
> > y <- rnorm(10)
> > plot(x, y)
> > #+end_src
> >
> > Same plot with larger dimension:
> >
> > #+begin_src R :file b.png :width 800 :height 800
> > plot(x, y)
> > #+end_src
> >
> >
> > Where do I wrong?
> >
> > Best
> > Riccardo
> > Hi, I'm trying to generate some figure with R, into an org session.
> Firstly I use the code in the org site. The problem is that the code do not
> generate any figure. This is the code:
> > #+TITLE:Test
> > #+AUTHOR: Your Name
> > #+EMAIL: mailto:your-email@server.com
> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
> :tangle yes
> >
> > * Example of Org-Babel for R Literate Programming
> > ** R text output
> > A simple summary.
> > #+begin_src R
> > x <- rnorm(10)
> > summary(x)
> > #+end_src
> >
> > ** R graphics output
> > Note we use the object =x= generated in previous code block, thanks to
> > the header option =:session *R*=. The output graphics file is
> > =a.png=.
> >
> > #+begin_src R :file a.png
> > y <- rnorm(10)
> > plot(x, y)
> > #+end_src
> >
> > Same plot with larger dimension:
> >
> > #+begin_src R :file b.png :width 800 :height 800
> > plot(x, y)
> > #+end_src
> > Where do I wrong?BestRiccardo
>
> --
> Thomas S. Dye
> http://www.tsdye.com
>
[-- Attachment #2: Type: text/html, Size: 3533 bytes --]
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Generating plot with org-babel-R
2012-02-05 11:08 ` Riccardo Romoli
@ 2012-02-05 16:45 ` Thomas S. Dye
2012-02-05 19:29 ` Updating the Babel section of Worg Was: " Eric Schulte
2012-02-06 21:12 ` Generating plot with org-babel-R Riccardo Romoli
0 siblings, 2 replies; 17+ messages in thread
From: Thomas S. Dye @ 2012-02-05 16:45 UTC (permalink / raw
To: Riccardo Romoli; +Cc: emacs-orgmode
Hi Riccardo,
Thanks for the URL. Org mode has evolved since this article was
written. It should probably be revised or taken off Worg. I've copied
Eric Schulte, who is better able than me to determine the correct course
of action here.
In the meantime, an up-to-date description of how Org mode can be used
to write literate programs has appeared in the Journal of Statistical
Software. You can find it here: http://www.jstatsoft.org/v46/i03
Perhaps you could use the examples in the JSS article to get started?
If these don't work for you, or if they raise questions that are difficult
to answer, please do come back to the list with your queries.
All the best,
Tom
Riccardo Romoli <ric.romoli@gmail.com> writes:
> Hi, this is the URL:
>
> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>
> Best
> R
>
> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>
>> Hi Riccardo,
>>
>> This code appears to be outdated. I don't recall this code on the org
>> site. Could you send a URL?
>>
>> All the best,
>> Tom
>>
>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>
>> > Hi, I'm trying to generate some figure with R, into an org session.
>> Firstly
>> > I use the code in the org site. The problem is that the code do not
>> > generate any figure.
>> >
>> > This is the code:
>> >
>> > #+TITLE:Test
>> > #+AUTHOR: Your Name
>> > #+EMAIL: your-email@server.com
>> > #+BABEL: :session *R* :cache yes :results output graphics :exports
>> > both :tangle yes
>> >
>> > * Example of Org-Babel for R Literate Programming
>> > ** R text output
>> > A simple summary.
>> > #+begin_src R
>> > x <- rnorm(10)
>> > summary(x)
>> > #+end_src
>> >
>> > ** R graphics output
>> > Note we use the object =x= generated in previous code block, thanks to
>> > the header option =:session *R*=. The output graphics file is
>> > =a.png=.
>> >
>> > #+begin_src R :file a.png
>> > y <- rnorm(10)
>> > plot(x, y)
>> > #+end_src
>> >
>> > Same plot with larger dimension:
>> >
>> > #+begin_src R :file b.png :width 800 :height 800
>> > plot(x, y)
>> > #+end_src
>> >
>> >
>> > Where do I wrong?
>> >
>> > Best
>> > Riccardo
>> > Hi, I'm trying to generate some figure with R, into an org session.
>> Firstly I use the code in the org site. The problem is that the code do not
>> generate any figure. This is the code:
>> > #+TITLE:Test
>> > #+AUTHOR: Your Name
>> > #+EMAIL: mailto:your-email@server.com
>> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
>> :tangle yes
>> >
>> > * Example of Org-Babel for R Literate Programming
>> > ** R text output
>> > A simple summary.
>> > #+begin_src R
>> > x <- rnorm(10)
>> > summary(x)
>> > #+end_src
>> >
>> > ** R graphics output
>> > Note we use the object =x= generated in previous code block, thanks to
>> > the header option =:session *R*=. The output graphics file is
>> > =a.png=.
>> >
>> > #+begin_src R :file a.png
>> > y <- rnorm(10)
>> > plot(x, y)
>> > #+end_src
>> >
>> > Same plot with larger dimension:
>> >
>> > #+begin_src R :file b.png :width 800 :height 800
>> > plot(x, y)
>> > #+end_src
>> > Where do I wrong?BestRiccardo
>>
>> --
>> Thomas S. Dye
>> http://www.tsdye.com
>>
> Hi, this is the URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
> 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi Riccardo,
>
>
> This code appears to be outdated. I don't recall this code on the org
> site. Could you send a URL?
>
> All the best,
> Tom
>
> Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
>
>> Hi, I'm trying to generate some figure with R, into an org session. Firstly
>> I use the code in the org site. The problem is that the code do not
>> generate any figure.
>>
>> This is the code:
>>
>> #+TITLE:Test
>> #+AUTHOR: Your Name
>> #+EMAIL: mailto:your-email@server.com
>> #+BABEL: :session *R* :cache yes :results output graphics :exports
>> both :tangle yes
>>
>> * Example of Org-Babel for R Literate Programming
>> ** R text output
>> A simple summary.
>> #+begin_src R
>> x <- rnorm(10)
>> summary(x)
>> #+end_src
>>
>> ** R graphics output
>> Note we use the object =x= generated in previous code block, thanks to
>> the header option =:session *R*=. The output graphics file is
>> =a.png=.
>>
>> #+begin_src R :file a.png
>> y <- rnorm(10)
>> plot(x, y)
>> #+end_src
>>
>> Same plot with larger dimension:
>>
>> #+begin_src R :file b.png :width 800 :height 800
>> plot(x, y)
>> #+end_src
>>
>>
>> Where do I wrong?
>>
>> Best
>> Riccardo
>> Hi, I'm trying to generate some figure with R, into an org session. Firstly I use the code in the org site. The problem is that the code do not generate any figure. This is the code:
>> #+TITLE:Test
>> #+AUTHOR: Your Name
>> #+EMAIL: mailto:mailto:your-email@server.com
>> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>>
>> * Example of Org-Babel for R Literate Programming
>> ** R text output
>> A simple summary.
>> #+begin_src R
>> x <- rnorm(10)
>> summary(x)
>> #+end_src
>>
>> ** R graphics output
>> Note we use the object =x= generated in previous code block, thanks to
>> the header option =:session *R*=. The output graphics file is
>> =a.png=.
>>
>> #+begin_src R :file a.png
>> y <- rnorm(10)
>> plot(x, y)
>> #+end_src
>>
>> Same plot with larger dimension:
>>
>> #+begin_src R :file b.png :width 800 :height 800
>> plot(x, y)
>> #+end_src
>> Where do I wrong?BestRiccardo
>
> <span class="HOEnZb">--
> Thomas S. Dye
> http://www.tsdye.com
> </span>
--
Thomas S. Dye
http://www.tsdye.com
^ permalink raw reply [flat|nested] 17+ messages in thread
* Updating the Babel section of Worg Was: Generating plot with org-babel-R
2012-02-05 16:45 ` Thomas S. Dye
@ 2012-02-05 19:29 ` Eric Schulte
2012-02-06 5:43 ` Thomas S. Dye
2012-02-06 21:12 ` Generating plot with org-babel-R Riccardo Romoli
1 sibling, 1 reply; 17+ messages in thread
From: Eric Schulte @ 2012-02-05 19:29 UTC (permalink / raw
To: Thomas S. Dye; +Cc: emacs-orgmode, Riccardo Romoli
Thanks for raising this point. The bulk of the content in the Babel
portion of worg is fairly old, predating the syntax standardization
efforts this fall. I've just pushed some minor updates to the main
babel pages, but updating the language-specific tutorials and the
individual use cases will be a much larger effort.
I'm not sure how to proceed. One option would be to go through and add
a [uses deprecated syntax] tag to the top of each such page, which could
be removed after the page has been checked and possibly updated to
ensure consistency with the latest syntax.
Given that the Babel syntax will not be changing significantly moving
forward now would be a good time to do such a review. Ideally this
could be completed before the release of Emacs 24 in a couple of months.
Any other ideas for update/reorganization or volunteers?
Cheers,
tsd@tsdye.com (Thomas S. Dye) writes:
> Hi Riccardo,
>
> Thanks for the URL. Org mode has evolved since this article was
> written. It should probably be revised or taken off Worg. I've copied
> Eric Schulte, who is better able than me to determine the correct course
> of action here.
>
> In the meantime, an up-to-date description of how Org mode can be used
> to write literate programs has appeared in the Journal of Statistical
> Software. You can find it here: http://www.jstatsoft.org/v46/i03
>
> Perhaps you could use the examples in the JSS article to get started?
> If these don't work for you, or if they raise questions that are difficult
> to answer, please do come back to the list with your queries.
>
> All the best,
> Tom
>
> Riccardo Romoli <ric.romoli@gmail.com> writes:
>
>> Hi, this is the URL:
>>
>> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>>
>> Best
>> R
>>
>> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>>
>>> Hi Riccardo,
>>>
>>> This code appears to be outdated. I don't recall this code on the org
>>> site. Could you send a URL?
>>>
>>> All the best,
>>> Tom
>>>
>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>
>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>> Firstly
>>> > I use the code in the org site. The problem is that the code do not
>>> > generate any figure.
>>> >
>>> > This is the code:
>>> >
>>> > #+TITLE:Test
>>> > #+AUTHOR: Your Name
>>> > #+EMAIL: your-email@server.com
>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports
>>> > both :tangle yes
>>> >
>>> > * Example of Org-Babel for R Literate Programming
>>> > ** R text output
>>> > A simple summary.
>>> > #+begin_src R
>>> > x <- rnorm(10)
>>> > summary(x)
>>> > #+end_src
>>> >
>>> > ** R graphics output
>>> > Note we use the object =x= generated in previous code block, thanks to
>>> > the header option =:session *R*=. The output graphics file is
>>> > =a.png=.
>>> >
>>> > #+begin_src R :file a.png
>>> > y <- rnorm(10)
>>> > plot(x, y)
>>> > #+end_src
>>> >
>>> > Same plot with larger dimension:
>>> >
>>> > #+begin_src R :file b.png :width 800 :height 800
>>> > plot(x, y)
>>> > #+end_src
>>> >
>>> >
>>> > Where do I wrong?
>>> >
>>> > Best
>>> > Riccardo
>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>> Firstly I use the code in the org site. The problem is that the code do not
>>> generate any figure. This is the code:
>>> > #+TITLE:Test
>>> > #+AUTHOR: Your Name
>>> > #+EMAIL: mailto:your-email@server.com
>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
>>> :tangle yes
>>> >
>>> > * Example of Org-Babel for R Literate Programming
>>> > ** R text output
>>> > A simple summary.
>>> > #+begin_src R
>>> > x <- rnorm(10)
>>> > summary(x)
>>> > #+end_src
>>> >
>>> > ** R graphics output
>>> > Note we use the object =x= generated in previous code block, thanks to
>>> > the header option =:session *R*=. The output graphics file is
>>> > =a.png=.
>>> >
>>> > #+begin_src R :file a.png
>>> > y <- rnorm(10)
>>> > plot(x, y)
>>> > #+end_src
>>> >
>>> > Same plot with larger dimension:
>>> >
>>> > #+begin_src R :file b.png :width 800 :height 800
>>> > plot(x, y)
>>> > #+end_src
>>> > Where do I wrong?BestRiccardo
>>>
>>> --
>>> Thomas S. Dye
>>> http://www.tsdye.com
>>>
>> Hi, this is the URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
>> 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi Riccardo,
>>
>>
>> This code appears to be outdated. I don't recall this code on the org
>> site. Could you send a URL?
>>
>> All the best,
>> Tom
>>
>> Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
>>
>>> Hi, I'm trying to generate some figure with R, into an org session. Firstly
>>> I use the code in the org site. The problem is that the code do not
>>> generate any figure.
>>>
>>> This is the code:
>>>
>>> #+TITLE:Test
>>> #+AUTHOR: Your Name
>>> #+EMAIL: mailto:your-email@server.com
>>> #+BABEL: :session *R* :cache yes :results output graphics :exports
>>> both :tangle yes
>>>
>>> * Example of Org-Babel for R Literate Programming
>>> ** R text output
>>> A simple summary.
>>> #+begin_src R
>>> x <- rnorm(10)
>>> summary(x)
>>> #+end_src
>>>
>>> ** R graphics output
>>> Note we use the object =x= generated in previous code block, thanks to
>>> the header option =:session *R*=. The output graphics file is
>>> =a.png=.
>>>
>>> #+begin_src R :file a.png
>>> y <- rnorm(10)
>>> plot(x, y)
>>> #+end_src
>>>
>>> Same plot with larger dimension:
>>>
>>> #+begin_src R :file b.png :width 800 :height 800
>>> plot(x, y)
>>> #+end_src
>>>
>>>
>>> Where do I wrong?
>>>
>>> Best
>>> Riccardo
>>> Hi, I'm trying to generate some figure with R, into an org
>>> session. Firstly I use the code in the org site. The problem is
>>> that the code do not generate any figure. This is the code:
>>> #+TITLE:Test
>>> #+AUTHOR: Your Name
>>> #+EMAIL: mailto:mailto:your-email@server.com
>>> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>>>
>>> * Example of Org-Babel for R Literate Programming
>>> ** R text output
>>> A simple summary.
>>> #+begin_src R
>>> x <- rnorm(10)
>>> summary(x)
>>> #+end_src
>>>
>>> ** R graphics output
>>> Note we use the object =x= generated in previous code block, thanks to
>>> the header option =:session *R*=. The output graphics file is
>>> =a.png=.
>>>
>>> #+begin_src R :file a.png
>>> y <- rnorm(10)
>>> plot(x, y)
>>> #+end_src
>>>
>>> Same plot with larger dimension:
>>>
>>> #+begin_src R :file b.png :width 800 :height 800
>>> plot(x, y)
>>> #+end_src
>>> Where do I wrong?BestRiccardo
>>
>> <span class="HOEnZb">--
>> Thomas S. Dye
>> http://www.tsdye.com
>> </span>
--
Eric Schulte
http://cs.unm.edu/~eschulte/
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Updating the Babel section of Worg Was: Generating plot with org-babel-R
2012-02-05 19:29 ` Updating the Babel section of Worg Was: " Eric Schulte
@ 2012-02-06 5:43 ` Thomas S. Dye
2012-02-06 21:20 ` Updating the Babel section of Worg Eric Schulte
0 siblings, 1 reply; 17+ messages in thread
From: Thomas S. Dye @ 2012-02-06 5:43 UTC (permalink / raw
To: Eric Schulte; +Cc: emacs-orgmode, Riccardo Romoli
Hi Eric,
Yes, this is overdue. I think your plan is a good one.
Perhaps a few of the individual use cases could be moved to FIXME,
instead? I'm thinking here of Feiming Chen's R setup and some of my
contributions when I was experimenting writing LaTeX inside source
code blocks. The authors could resurrect these as they see fit.
Hopefully, others will contribute use examples. My sense from reading
the list is there are many interesting ones.
I'd like it if Org mode users designed a template for the language
specific pages. Currently, these seem to me a mixed bag and it would be
good to regularize them. It would also be nice to have one for each of
the supported languages. There are 11 language specific pages now,
which leaves quite a few languages under-documented.
I'll be happy to work on this as I can.
All the best,
Tom
Eric Schulte <eric.schulte@gmx.com> writes:
> Thanks for raising this point. The bulk of the content in the Babel
> portion of worg is fairly old, predating the syntax standardization
> efforts this fall. I've just pushed some minor updates to the main
> babel pages, but updating the language-specific tutorials and the
> individual use cases will be a much larger effort.
>
> I'm not sure how to proceed. One option would be to go through and add
> a [uses deprecated syntax] tag to the top of each such page, which could
> be removed after the page has been checked and possibly updated to
> ensure consistency with the latest syntax.
>
> Given that the Babel syntax will not be changing significantly moving
> forward now would be a good time to do such a review. Ideally this
> could be completed before the release of Emacs 24 in a couple of months.
>
> Any other ideas for update/reorganization or volunteers?
>
> Cheers,
>
> tsd@tsdye.com (Thomas S. Dye) writes:
>
>> Hi Riccardo,
>>
>> Thanks for the URL. Org mode has evolved since this article was
>> written. It should probably be revised or taken off Worg. I've copied
>> Eric Schulte, who is better able than me to determine the correct course
>> of action here.
>>
>> In the meantime, an up-to-date description of how Org mode can be used
>> to write literate programs has appeared in the Journal of Statistical
>> Software. You can find it here: http://www.jstatsoft.org/v46/i03
>>
>> Perhaps you could use the examples in the JSS article to get started?
>> If these don't work for you, or if they raise questions that are difficult
>> to answer, please do come back to the list with your queries.
>>
>> All the best,
>> Tom
>>
>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>
>>> Hi, this is the URL:
>>>
>>> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>>>
>>> Best
>>> R
>>>
>>> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>>>
>>>> Hi Riccardo,
>>>>
>>>> This code appears to be outdated. I don't recall this code on the org
>>>> site. Could you send a URL?
>>>>
>>>> All the best,
>>>> Tom
>>>>
>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>
>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>> Firstly
>>>> > I use the code in the org site. The problem is that the code do not
>>>> > generate any figure.
>>>> >
>>>> > This is the code:
>>>> >
>>>> > #+TITLE:Test
>>>> > #+AUTHOR: Your Name
>>>> > #+EMAIL: your-email@server.com
>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>> > both :tangle yes
>>>> >
>>>> > * Example of Org-Babel for R Literate Programming
>>>> > ** R text output
>>>> > A simple summary.
>>>> > #+begin_src R
>>>> > x <- rnorm(10)
>>>> > summary(x)
>>>> > #+end_src
>>>> >
>>>> > ** R graphics output
>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>> > the header option =:session *R*=. The output graphics file is
>>>> > =a.png=.
>>>> >
>>>> > #+begin_src R :file a.png
>>>> > y <- rnorm(10)
>>>> > plot(x, y)
>>>> > #+end_src
>>>> >
>>>> > Same plot with larger dimension:
>>>> >
>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>> > plot(x, y)
>>>> > #+end_src
>>>> >
>>>> >
>>>> > Where do I wrong?
>>>> >
>>>> > Best
>>>> > Riccardo
>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>> Firstly I use the code in the org site. The problem is that the code do not
>>>> generate any figure. This is the code:
>>>> > #+TITLE:Test
>>>> > #+AUTHOR: Your Name
>>>> > #+EMAIL: mailto:your-email@server.com
>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
>>>> :tangle yes
>>>> >
>>>> > * Example of Org-Babel for R Literate Programming
>>>> > ** R text output
>>>> > A simple summary.
>>>> > #+begin_src R
>>>> > x <- rnorm(10)
>>>> > summary(x)
>>>> > #+end_src
>>>> >
>>>> > ** R graphics output
>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>> > the header option =:session *R*=. The output graphics file is
>>>> > =a.png=.
>>>> >
>>>> > #+begin_src R :file a.png
>>>> > y <- rnorm(10)
>>>> > plot(x, y)
>>>> > #+end_src
>>>> >
>>>> > Same plot with larger dimension:
>>>> >
>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>> > plot(x, y)
>>>> > #+end_src
>>>> > Where do I wrong?BestRiccardo
>>>>
>>>> --
>>>> Thomas S. Dye
>>>> http://www.tsdye.com
>>>>
>>> Hi, this is the URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
>>> 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi Riccardo,
>>>
>>>
>>> This code appears to be outdated. I don't recall this code on the org
>>> site. Could you send a URL?
>>>
>>> All the best,
>>> Tom
>>>
>>> Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
>>>
>>>> Hi, I'm trying to generate some figure with R, into an org session. Firstly
>>>> I use the code in the org site. The problem is that the code do not
>>>> generate any figure.
>>>>
>>>> This is the code:
>>>>
>>>> #+TITLE:Test
>>>> #+AUTHOR: Your Name
>>>> #+EMAIL: mailto:your-email@server.com
>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>> both :tangle yes
>>>>
>>>> * Example of Org-Babel for R Literate Programming
>>>> ** R text output
>>>> A simple summary.
>>>> #+begin_src R
>>>> x <- rnorm(10)
>>>> summary(x)
>>>> #+end_src
>>>>
>>>> ** R graphics output
>>>> Note we use the object =x= generated in previous code block, thanks to
>>>> the header option =:session *R*=. The output graphics file is
>>>> =a.png=.
>>>>
>>>> #+begin_src R :file a.png
>>>> y <- rnorm(10)
>>>> plot(x, y)
>>>> #+end_src
>>>>
>>>> Same plot with larger dimension:
>>>>
>>>> #+begin_src R :file b.png :width 800 :height 800
>>>> plot(x, y)
>>>> #+end_src
>>>>
>>>>
>>>> Where do I wrong?
>>>>
>>>> Best
>>>> Riccardo
>>>> Hi, I'm trying to generate some figure with R, into an org
>>>> session. Firstly I use the code in the org site. The problem is
>>>> that the code do not generate any figure. This is the code:
>>>> #+TITLE:Test
>>>> #+AUTHOR: Your Name
>>>> #+EMAIL: mailto:mailto:your-email@server.com
>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>>>>
>>>> * Example of Org-Babel for R Literate Programming
>>>> ** R text output
>>>> A simple summary.
>>>> #+begin_src R
>>>> x <- rnorm(10)
>>>> summary(x)
>>>> #+end_src
>>>>
>>>> ** R graphics output
>>>> Note we use the object =x= generated in previous code block, thanks to
>>>> the header option =:session *R*=. The output graphics file is
>>>> =a.png=.
>>>>
>>>> #+begin_src R :file a.png
>>>> y <- rnorm(10)
>>>> plot(x, y)
>>>> #+end_src
>>>>
>>>> Same plot with larger dimension:
>>>>
>>>> #+begin_src R :file b.png :width 800 :height 800
>>>> plot(x, y)
>>>> #+end_src
>>>> Where do I wrong?BestRiccardo
>>>
>>> <span class="HOEnZb">--
>>> Thomas S. Dye
>>> http://www.tsdye.com
>>> </span>
--
Thomas S. Dye
http://www.tsdye.com
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Generating plot with org-babel-R
2012-02-05 16:45 ` Thomas S. Dye
2012-02-05 19:29 ` Updating the Babel section of Worg Was: " Eric Schulte
@ 2012-02-06 21:12 ` Riccardo Romoli
1 sibling, 0 replies; 17+ messages in thread
From: Riccardo Romoli @ 2012-02-06 21:12 UTC (permalink / raw
To: Thomas S. Dye; +Cc: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 6233 bytes --]
Hi Thomas,
thanks a lot for your help!! Using the JSS and the org manual I solved all
my problem (....at least for now!! :))
Best
Riccardo
2012/2/5 Thomas S. Dye <tsd@tsdye.com>
> Hi Riccardo,
>
> Thanks for the URL. Org mode has evolved since this article was
> written. It should probably be revised or taken off Worg. I've copied
> Eric Schulte, who is better able than me to determine the correct course
> of action here.
>
> In the meantime, an up-to-date description of how Org mode can be used
> to write literate programs has appeared in the Journal of Statistical
> Software. You can find it here: http://www.jstatsoft.org/v46/i03
>
> Perhaps you could use the examples in the JSS article to get started?
> If these don't work for you, or if they raise questions that are difficult
> to answer, please do come back to the list with your queries.
>
> All the best,
> Tom
>
> Riccardo Romoli <ric.romoli@gmail.com> writes:
>
> > Hi, this is the URL:
> >
> >
> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
> >
> > Best
> > R
> >
> > 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
> >
> >> Hi Riccardo,
> >>
> >> This code appears to be outdated. I don't recall this code on the org
> >> site. Could you send a URL?
> >>
> >> All the best,
> >> Tom
> >>
> >> Riccardo Romoli <ric.romoli@gmail.com> writes:
> >>
> >> > Hi, I'm trying to generate some figure with R, into an org session.
> >> Firstly
> >> > I use the code in the org site. The problem is that the code do not
> >> > generate any figure.
> >> >
> >> > This is the code:
> >> >
> >> > #+TITLE:Test
> >> > #+AUTHOR: Your Name
> >> > #+EMAIL: your-email@server.com
> >> > #+BABEL: :session *R* :cache yes :results output graphics :exports
> >> > both :tangle yes
> >> >
> >> > * Example of Org-Babel for R Literate Programming
> >> > ** R text output
> >> > A simple summary.
> >> > #+begin_src R
> >> > x <- rnorm(10)
> >> > summary(x)
> >> > #+end_src
> >> >
> >> > ** R graphics output
> >> > Note we use the object =x= generated in previous code block, thanks to
> >> > the header option =:session *R*=. The output graphics file is
> >> > =a.png=.
> >> >
> >> > #+begin_src R :file a.png
> >> > y <- rnorm(10)
> >> > plot(x, y)
> >> > #+end_src
> >> >
> >> > Same plot with larger dimension:
> >> >
> >> > #+begin_src R :file b.png :width 800 :height 800
> >> > plot(x, y)
> >> > #+end_src
> >> >
> >> >
> >> > Where do I wrong?
> >> >
> >> > Best
> >> > Riccardo
> >> > Hi, I'm trying to generate some figure with R, into an org
> session.
> >> Firstly I use the code in the org site. The problem is that the code do
> not
> >> generate any figure. This is the code:
> >> > #+TITLE:Test
> >> > #+AUTHOR: Your Name
> >> > #+EMAIL: mailto:your-email@server.com
> >> > #+BABEL: :session *R* :cache yes :results output graphics :exports
> both
> >> :tangle yes
> >> >
> >> > * Example of Org-Babel for R Literate Programming
> >> > ** R text output
> >> > A simple summary.
> >> > #+begin_src R
> >> > x <- rnorm(10)
> >> > summary(x)
> >> > #+end_src
> >> >
> >> > ** R graphics output
> >> > Note we use the object =x= generated in previous code block, thanks to
> >> > the header option =:session *R*=. The output graphics file is
> >> > =a.png=.
> >> >
> >> > #+begin_src R :file a.png
> >> > y <- rnorm(10)
> >> > plot(x, y)
> >> > #+end_src
> >> >
> >> > Same plot with larger dimension:
> >> >
> >> > #+begin_src R :file b.png :width 800 :height 800
> >> > plot(x, y)
> >> > #+end_src
> >> > Where do I wrong?BestRiccardo
> >>
> >> --
> >> Thomas S. Dye
> >> http://www.tsdye.com
> >>
> > Hi, this is the URL:
> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
> > 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi
> Riccardo,
> >
> >
> > This code appears to be outdated. I don't recall this code on the
> org
> > site. Could you send a URL?
> >
> > All the best,
> > Tom
> >
> > Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
> >
> >> Hi, I'm trying to generate some figure with R, into an org session.
> Firstly
> >> I use the code in the org site. The problem is that the code do not
> >> generate any figure.
> >>
> >> This is the code:
> >>
> >> #+TITLE:Test
> >> #+AUTHOR: Your Name
> >> #+EMAIL: mailto:your-email@server.com
> >> #+BABEL: :session *R* :cache yes :results output graphics :exports
> >> both :tangle yes
> >>
> >> * Example of Org-Babel for R Literate Programming
> >> ** R text output
> >> A simple summary.
> >> #+begin_src R
> >> x <- rnorm(10)
> >> summary(x)
> >> #+end_src
> >>
> >> ** R graphics output
> >> Note we use the object =x= generated in previous code block, thanks to
> >> the header option =:session *R*=. The output graphics file is
> >> =a.png=.
> >>
> >> #+begin_src R :file a.png
> >> y <- rnorm(10)
> >> plot(x, y)
> >> #+end_src
> >>
> >> Same plot with larger dimension:
> >>
> >> #+begin_src R :file b.png :width 800 :height 800
> >> plot(x, y)
> >> #+end_src
> >>
> >>
> >> Where do I wrong?
> >>
> >> Best
> >> Riccardo
> >> Hi, I'm trying to generate some figure with R, into an org session.
> Firstly I use the code in the org site. The problem is that the code do not
> generate any figure. This is the code:
> >> #+TITLE:Test
> >> #+AUTHOR: Your Name
> >> #+EMAIL: mailto:mailto:your-email@server.com
> >> #+BABEL: :session *R* :cache yes :results output graphics :exports both
> :tangle yes
> >>
> >> * Example of Org-Babel for R Literate Programming
> >> ** R text output
> >> A simple summary.
> >> #+begin_src R
> >> x <- rnorm(10)
> >> summary(x)
> >> #+end_src
> >>
> >> ** R graphics output
> >> Note we use the object =x= generated in previous code block, thanks to
> >> the header option =:session *R*=. The output graphics file is
> >> =a.png=.
> >>
> >> #+begin_src R :file a.png
> >> y <- rnorm(10)
> >> plot(x, y)
> >> #+end_src
> >>
> >> Same plot with larger dimension:
> >>
> >> #+begin_src R :file b.png :width 800 :height 800
> >> plot(x, y)
> >> #+end_src
> >> Where do I wrong?BestRiccardo
> >
> > <span class="HOEnZb">--
> > Thomas S. Dye
> > http://www.tsdye.com
> > </span>
>
> --
> Thomas S. Dye
> http://www.tsdye.com
>
[-- Attachment #2: Type: text/html, Size: 9503 bytes --]
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Updating the Babel section of Worg
2012-02-06 5:43 ` Thomas S. Dye
@ 2012-02-06 21:20 ` Eric Schulte
2012-02-08 0:01 ` Thomas S. Dye
0 siblings, 1 reply; 17+ messages in thread
From: Eric Schulte @ 2012-02-06 21:20 UTC (permalink / raw
To: Thomas S. Dye; +Cc: emacs-orgmode, Eric Schulte, Riccardo Romoli
Hi Tom,
tsd@tsdye.com (Thomas S. Dye) writes:
> Hi Eric,
>
> Yes, this is overdue. I think your plan is a good one.
>
> Perhaps a few of the individual use cases could be moved to FIXME,
> instead? I'm thinking here of Feiming Chen's R setup and some of my
> contributions when I was experimenting writing LaTeX inside source
> code blocks. The authors could resurrect these as they see fit.
>
I don't know what FIXME is, but if there is a way to keep the page in
the worg git repository but remove it from the exported HTML then that
sounds ideal.
>
> Hopefully, others will contribute use examples. My sense from reading
> the list is there are many interesting ones.
>
> I'd like it if Org mode users designed a template for the language
> specific pages. Currently, these seem to me a mixed bag and it would be
> good to regularize them.
The below is a modified version of a template which can be found in a
couple of the existing language tutorials, I think it serves as a good
starting point.
- Install and Setup
- Instillation and configuration of software (e.g., the language itself)
- Configuration of Emacs (e.g., activate language, set command path)
- Examples
- Common ways to use the language in an Org-mode document
- Special cases
- are there any language-specific header arguments
- does the language support session evaluation
- does the language support all result types
- is the language different from most babel languages
(e.g., C is compiled before execution, ditaa returns files, etc...)
> It would also be nice to have one for each of the supported languages.
> There are 11 language specific pages now, which leaves quite a few
> languages under-documented.
(length org-babel-load-languages) ;; => 27
ls org-contrib/babel/languages/ob-doc-*|wc -l # => 11
It looks like we have at least 16 more to go before we hit full language
coverage. Perhaps we should use the empty cells in the "documentation"
column in the languages table at [1] as a sign up space for volunteers
who would be willing to write a brief tutorial demonstrating usage of
Org-mode with their favorite language.
Moving forward this is likely something we could request of the
contributors of new languages.
Also, once the template above is finalized it should be posted on worg
and linked to through the languages page.
>
> I'll be happy to work on this as I can.
>
Great, I don't anticipate having time to put towards this, although I'll
be happy to help troubleshoot where I can.
Cheers,
>
> All the best,
> Tom
>
>
> Eric Schulte <eric.schulte@gmx.com> writes:
>
>> Thanks for raising this point. The bulk of the content in the Babel
>> portion of worg is fairly old, predating the syntax standardization
>> efforts this fall. I've just pushed some minor updates to the main
>> babel pages, but updating the language-specific tutorials and the
>> individual use cases will be a much larger effort.
>>
>> I'm not sure how to proceed. One option would be to go through and add
>> a [uses deprecated syntax] tag to the top of each such page, which could
>> be removed after the page has been checked and possibly updated to
>> ensure consistency with the latest syntax.
>>
>> Given that the Babel syntax will not be changing significantly moving
>> forward now would be a good time to do such a review. Ideally this
>> could be completed before the release of Emacs 24 in a couple of months.
>>
>> Any other ideas for update/reorganization or volunteers?
>>
>> Cheers,
>>
>> tsd@tsdye.com (Thomas S. Dye) writes:
>>
>>> Hi Riccardo,
>>>
>>> Thanks for the URL. Org mode has evolved since this article was
>>> written. It should probably be revised or taken off Worg. I've copied
>>> Eric Schulte, who is better able than me to determine the correct course
>>> of action here.
>>>
>>> In the meantime, an up-to-date description of how Org mode can be used
>>> to write literate programs has appeared in the Journal of Statistical
>>> Software. You can find it here: http://www.jstatsoft.org/v46/i03
>>>
>>> Perhaps you could use the examples in the JSS article to get started?
>>> If these don't work for you, or if they raise questions that are difficult
>>> to answer, please do come back to the list with your queries.
>>>
>>> All the best,
>>> Tom
>>>
>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>
>>>> Hi, this is the URL:
>>>>
>>>> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>>>>
>>>> Best
>>>> R
>>>>
>>>> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>>>>
>>>>> Hi Riccardo,
>>>>>
>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>> site. Could you send a URL?
>>>>>
>>>>> All the best,
>>>>> Tom
>>>>>
>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>
>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>> Firstly
>>>>> > I use the code in the org site. The problem is that the code do not
>>>>> > generate any figure.
>>>>> >
>>>>> > This is the code:
>>>>> >
>>>>> > #+TITLE:Test
>>>>> > #+AUTHOR: Your Name
>>>>> > #+EMAIL: your-email@server.com
>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>> > both :tangle yes
>>>>> >
>>>>> > * Example of Org-Babel for R Literate Programming
>>>>> > ** R text output
>>>>> > A simple summary.
>>>>> > #+begin_src R
>>>>> > x <- rnorm(10)
>>>>> > summary(x)
>>>>> > #+end_src
>>>>> >
>>>>> > ** R graphics output
>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>> > the header option =:session *R*=. The output graphics file is
>>>>> > =a.png=.
>>>>> >
>>>>> > #+begin_src R :file a.png
>>>>> > y <- rnorm(10)
>>>>> > plot(x, y)
>>>>> > #+end_src
>>>>> >
>>>>> > Same plot with larger dimension:
>>>>> >
>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>> > plot(x, y)
>>>>> > #+end_src
>>>>> >
>>>>> >
>>>>> > Where do I wrong?
>>>>> >
>>>>> > Best
>>>>> > Riccardo
>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>> Firstly I use the code in the org site. The problem is that the code do not
>>>>> generate any figure. This is the code:
>>>>> > #+TITLE:Test
>>>>> > #+AUTHOR: Your Name
>>>>> > #+EMAIL: mailto:your-email@server.com
>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
>>>>> :tangle yes
>>>>> >
>>>>> > * Example of Org-Babel for R Literate Programming
>>>>> > ** R text output
>>>>> > A simple summary.
>>>>> > #+begin_src R
>>>>> > x <- rnorm(10)
>>>>> > summary(x)
>>>>> > #+end_src
>>>>> >
>>>>> > ** R graphics output
>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>> > the header option =:session *R*=. The output graphics file is
>>>>> > =a.png=.
>>>>> >
>>>>> > #+begin_src R :file a.png
>>>>> > y <- rnorm(10)
>>>>> > plot(x, y)
>>>>> > #+end_src
>>>>> >
>>>>> > Same plot with larger dimension:
>>>>> >
>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>> > plot(x, y)
>>>>> > #+end_src
>>>>> > Where do I wrong?BestRiccardo
>>>>>
>>>>> --
>>>>> Thomas S. Dye
>>>>> http://www.tsdye.com
>>>>>
>>>> Hi, this is the URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
>>>> 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi Riccardo,
>>>>
>>>>
>>>> This code appears to be outdated. I don't recall this code on the org
>>>> site. Could you send a URL?
>>>>
>>>> All the best,
>>>> Tom
>>>>
>>>> Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
>>>>
>>>>> Hi, I'm trying to generate some figure with R, into an org session. Firstly
>>>>> I use the code in the org site. The problem is that the code do not
>>>>> generate any figure.
>>>>>
>>>>> This is the code:
>>>>>
>>>>> #+TITLE:Test
>>>>> #+AUTHOR: Your Name
>>>>> #+EMAIL: mailto:your-email@server.com
>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>> both :tangle yes
>>>>>
>>>>> * Example of Org-Babel for R Literate Programming
>>>>> ** R text output
>>>>> A simple summary.
>>>>> #+begin_src R
>>>>> x <- rnorm(10)
>>>>> summary(x)
>>>>> #+end_src
>>>>>
>>>>> ** R graphics output
>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>> the header option =:session *R*=. The output graphics file is
>>>>> =a.png=.
>>>>>
>>>>> #+begin_src R :file a.png
>>>>> y <- rnorm(10)
>>>>> plot(x, y)
>>>>> #+end_src
>>>>>
>>>>> Same plot with larger dimension:
>>>>>
>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>> plot(x, y)
>>>>> #+end_src
>>>>>
>>>>>
>>>>> Where do I wrong?
>>>>>
>>>>> Best
>>>>> Riccardo
>>>>> Hi, I'm trying to generate some figure with R, into an org
>>>>> session. Firstly I use the code in the org site. The problem is
>>>>> that the code do not generate any figure. This is the code:
>>>>> #+TITLE:Test
>>>>> #+AUTHOR: Your Name
>>>>> #+EMAIL: mailto:mailto:your-email@server.com
>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>>>>>
>>>>> * Example of Org-Babel for R Literate Programming
>>>>> ** R text output
>>>>> A simple summary.
>>>>> #+begin_src R
>>>>> x <- rnorm(10)
>>>>> summary(x)
>>>>> #+end_src
>>>>>
>>>>> ** R graphics output
>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>> the header option =:session *R*=. The output graphics file is
>>>>> =a.png=.
>>>>>
>>>>> #+begin_src R :file a.png
>>>>> y <- rnorm(10)
>>>>> plot(x, y)
>>>>> #+end_src
>>>>>
>>>>> Same plot with larger dimension:
>>>>>
>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>> plot(x, y)
>>>>> #+end_src
>>>>> Where do I wrong?BestRiccardo
>>>>
>>>> <span class="HOEnZb">--
>>>> Thomas S. Dye
>>>> http://www.tsdye.com
>>>> </span>
Footnotes:
[1] http://orgmode.org/worg/org-contrib/babel/languages.html
--
Eric Schulte
http://cs.unm.edu/~eschulte/
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Updating the Babel section of Worg
2012-02-06 21:20 ` Updating the Babel section of Worg Eric Schulte
@ 2012-02-08 0:01 ` Thomas S. Dye
2012-02-08 1:04 ` Martyn Jago
` (2 more replies)
0 siblings, 3 replies; 17+ messages in thread
From: Thomas S. Dye @ 2012-02-08 0:01 UTC (permalink / raw
To: Eric Schulte; +Cc: emacs-orgmode, Riccardo Romoli
[-- Attachment #1: Type: text/plain, Size: 252 bytes --]
Hi Eric,
I've attached a first draft of a template for review and revision. It
is heavily influenced by John Hendy's terrific gnuplot page. I
believe it incorporates the points in your outline. Feel free to
edit as appropriate.
All the best,
Tom
[-- Attachment #2: Language description template --]
[-- Type: text/plain, Size: 2650 bytes --]
#+OPTIONS: H:3 num:nil toc:2 \n:nil @:t ::t |:t ^:{} -:t f:t *:t TeX:t LaTeX:t skip:nil d:(HIDE) tags:not-in-toc
#+STARTUP: align fold nodlcheck hidestars oddeven lognotestate hideblocks
#+SEQ_TODO: TODO(t) INPROGRESS(i) WAITING(w@) | DONE(d) CANCELED(c@)
#+TAGS: Write(w) Update(u) Fix(f) Check(c) noexport(n)
#+TITLE: Language Source Code Blocks in Org Mode
#+AUTHOR: Your name
#+EMAIL: you[at]email[dot]org
#+LANGUAGE: en
#+STYLE: <style type="text/css">#outline-container-introduction{ clear:both; }</style>
#+LINK_UP: ../languages.php
#+LINK_HOME: http://orgmode.org/worg/
#+EXPORT_EXCLUDE_TAGS: noexport
#+name: banner
#+begin_html
<div id="subtitle" style="float: center; text-align: center;">
<p>
Org Mode support for <a href="http://language-site/">Language</a>
</p>
<p>
<a href="http://language-site/">
<img src="http://language-site/graphic.file"/>
</a>
</p>
</div>
#+end_html
* Template Checklist [0/13] :noexport:
- [ ] Revise #+TITLE:
- [ ] Indicate #+AUTHOR:
- [ ] Add #+EMAIL:
- [ ] Revise banner source block [0/3]
- [ ] Add link to a useful language web site
- [ ] Replace "Language" with language name
- [ ] Find a suitable graphic and use it to link to the language
web site
- [ ] Write an [[Introduction]]
- [ ] Describe [[Requirements%20and%20Setup][Requirements and Setup]]
- [ ] Replace "Language" with language name in [[Org%20Mode%20Features%20for%20Language%20Source%20Code%20Blocks][Org Mode Features for Language Source Code Blocks]]
- [ ] Specify [[Org%20Mode%20Configuration][Org Mode Configuration]]
- [ ] Describe [[Header%20Arguments][Header Arguments]]
- [ ] Describe support for [[Sessions]]
- [ ] Describe [[Result%20Types][Result Types]]
- [ ] Describe [[Other]] differences from supported languages
- [ ] Provide brief [[Examples%20of%20Use][Examples of Use]]
* Introduction
- Brief description of language.
- Range of typical uses within Org Mode.
- Link to this Org Mode file.
* Requirements and Setup
- Installation and configuration of language software
- Emacs configuration
* Org Mode Features for Language Source Code Blocks
** Org Mode Configuration
- org-babel-do-load-languages
** Header Arguments
- Language-specific default values
- Language-specific header arguments
** Sessions
- Support or not
- Typical use for sessions
** Result Types
- Which result types are supported?
** Other
- Differences from other supported languages
* Examples of Use
- Hello World!
- Common uses
- Links to tutorials and other resources
[-- Attachment #3: Type: text/plain, Size: 10620 bytes --]
Eric Schulte <eric.schulte@gmx.com> writes:
> Hi Tom,
>
> tsd@tsdye.com (Thomas S. Dye) writes:
>
>> Hi Eric,
>>
>> Yes, this is overdue. I think your plan is a good one.
>>
>> Perhaps a few of the individual use cases could be moved to FIXME,
>> instead? I'm thinking here of Feiming Chen's R setup and some of my
>> contributions when I was experimenting writing LaTeX inside source
>> code blocks. The authors could resurrect these as they see fit.
>>
>
> I don't know what FIXME is, but if there is a way to keep the page in
> the worg git repository but remove it from the exported HTML then that
> sounds ideal.
>
>>
>> Hopefully, others will contribute use examples. My sense from reading
>> the list is there are many interesting ones.
>>
>> I'd like it if Org mode users designed a template for the language
>> specific pages. Currently, these seem to me a mixed bag and it would be
>> good to regularize them.
>
> The below is a modified version of a template which can be found in a
> couple of the existing language tutorials, I think it serves as a good
> starting point.
>
> - Install and Setup
> - Instillation and configuration of software (e.g., the language itself)
> - Configuration of Emacs (e.g., activate language, set command path)
> - Examples
> - Common ways to use the language in an Org-mode document
> - Special cases
> - are there any language-specific header arguments
> - does the language support session evaluation
> - does the language support all result types
> - is the language different from most babel languages
> (e.g., C is compiled before execution, ditaa returns files, etc...)
>
>> It would also be nice to have one for each of the supported languages.
>> There are 11 language specific pages now, which leaves quite a few
>> languages under-documented.
>
> (length org-babel-load-languages) ;; => 27
>
> ls org-contrib/babel/languages/ob-doc-*|wc -l # => 11
>
> It looks like we have at least 16 more to go before we hit full language
> coverage. Perhaps we should use the empty cells in the "documentation"
> column in the languages table at [1] as a sign up space for volunteers
> who would be willing to write a brief tutorial demonstrating usage of
> Org-mode with their favorite language.
>
> Moving forward this is likely something we could request of the
> contributors of new languages.
>
> Also, once the template above is finalized it should be posted on worg
> and linked to through the languages page.
>
>>
>> I'll be happy to work on this as I can.
>>
>
> Great, I don't anticipate having time to put towards this, although I'll
> be happy to help troubleshoot where I can.
>
> Cheers,
>
>>
>> All the best,
>> Tom
>>
>>
>> Eric Schulte <eric.schulte@gmx.com> writes:
>>
>>> Thanks for raising this point. The bulk of the content in the Babel
>>> portion of worg is fairly old, predating the syntax standardization
>>> efforts this fall. I've just pushed some minor updates to the main
>>> babel pages, but updating the language-specific tutorials and the
>>> individual use cases will be a much larger effort.
>>>
>>> I'm not sure how to proceed. One option would be to go through and add
>>> a [uses deprecated syntax] tag to the top of each such page, which could
>>> be removed after the page has been checked and possibly updated to
>>> ensure consistency with the latest syntax.
>>>
>>> Given that the Babel syntax will not be changing significantly moving
>>> forward now would be a good time to do such a review. Ideally this
>>> could be completed before the release of Emacs 24 in a couple of months.
>>>
>>> Any other ideas for update/reorganization or volunteers?
>>>
>>> Cheers,
>>>
>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>
>>>> Hi Riccardo,
>>>>
>>>> Thanks for the URL. Org mode has evolved since this article was
>>>> written. It should probably be revised or taken off Worg. I've copied
>>>> Eric Schulte, who is better able than me to determine the correct course
>>>> of action here.
>>>>
>>>> In the meantime, an up-to-date description of how Org mode can be used
>>>> to write literate programs has appeared in the Journal of Statistical
>>>> Software. You can find it here: http://www.jstatsoft.org/v46/i03
>>>>
>>>> Perhaps you could use the examples in the JSS article to get started?
>>>> If these don't work for you, or if they raise questions that are difficult
>>>> to answer, please do come back to the list with your queries.
>>>>
>>>> All the best,
>>>> Tom
>>>>
>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>
>>>>> Hi, this is the URL:
>>>>>
>>>>> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>>>>>
>>>>> Best
>>>>> R
>>>>>
>>>>> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>>>>>
>>>>>> Hi Riccardo,
>>>>>>
>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>> site. Could you send a URL?
>>>>>>
>>>>>> All the best,
>>>>>> Tom
>>>>>>
>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>
>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>> Firstly
>>>>>> > I use the code in the org site. The problem is that the code do not
>>>>>> > generate any figure.
>>>>>> >
>>>>>> > This is the code:
>>>>>> >
>>>>>> > #+TITLE:Test
>>>>>> > #+AUTHOR: Your Name
>>>>>> > #+EMAIL: your-email@server.com
>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>> > both :tangle yes
>>>>>> >
>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>> > ** R text output
>>>>>> > A simple summary.
>>>>>> > #+begin_src R
>>>>>> > x <- rnorm(10)
>>>>>> > summary(x)
>>>>>> > #+end_src
>>>>>> >
>>>>>> > ** R graphics output
>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>> > =a.png=.
>>>>>> >
>>>>>> > #+begin_src R :file a.png
>>>>>> > y <- rnorm(10)
>>>>>> > plot(x, y)
>>>>>> > #+end_src
>>>>>> >
>>>>>> > Same plot with larger dimension:
>>>>>> >
>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>> > plot(x, y)
>>>>>> > #+end_src
>>>>>> >
>>>>>> >
>>>>>> > Where do I wrong?
>>>>>> >
>>>>>> > Best
>>>>>> > Riccardo
>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>> Firstly I use the code in the org site. The problem is that the code do not
>>>>>> generate any figure. This is the code:
>>>>>> > #+TITLE:Test
>>>>>> > #+AUTHOR: Your Name
>>>>>> > #+EMAIL: mailto:your-email@server.com
>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
>>>>>> :tangle yes
>>>>>> >
>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>> > ** R text output
>>>>>> > A simple summary.
>>>>>> > #+begin_src R
>>>>>> > x <- rnorm(10)
>>>>>> > summary(x)
>>>>>> > #+end_src
>>>>>> >
>>>>>> > ** R graphics output
>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>> > =a.png=.
>>>>>> >
>>>>>> > #+begin_src R :file a.png
>>>>>> > y <- rnorm(10)
>>>>>> > plot(x, y)
>>>>>> > #+end_src
>>>>>> >
>>>>>> > Same plot with larger dimension:
>>>>>> >
>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>> > plot(x, y)
>>>>>> > #+end_src
>>>>>> > Where do I wrong?BestRiccardo
>>>>>>
>>>>>> --
>>>>>> Thomas S. Dye
>>>>>> http://www.tsdye.com
>>>>>>
>>>>> Hi, this is the URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
>>>>> 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi Riccardo,
>>>>>
>>>>>
>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>> site. Could you send a URL?
>>>>>
>>>>> All the best,
>>>>> Tom
>>>>>
>>>>> Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
>>>>>
>>>>>> Hi, I'm trying to generate some figure with R, into an org session. Firstly
>>>>>> I use the code in the org site. The problem is that the code do not
>>>>>> generate any figure.
>>>>>>
>>>>>> This is the code:
>>>>>>
>>>>>> #+TITLE:Test
>>>>>> #+AUTHOR: Your Name
>>>>>> #+EMAIL: mailto:your-email@server.com
>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>> both :tangle yes
>>>>>>
>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>> ** R text output
>>>>>> A simple summary.
>>>>>> #+begin_src R
>>>>>> x <- rnorm(10)
>>>>>> summary(x)
>>>>>> #+end_src
>>>>>>
>>>>>> ** R graphics output
>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>> =a.png=.
>>>>>>
>>>>>> #+begin_src R :file a.png
>>>>>> y <- rnorm(10)
>>>>>> plot(x, y)
>>>>>> #+end_src
>>>>>>
>>>>>> Same plot with larger dimension:
>>>>>>
>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>> plot(x, y)
>>>>>> #+end_src
>>>>>>
>>>>>>
>>>>>> Where do I wrong?
>>>>>>
>>>>>> Best
>>>>>> Riccardo
>>>>>> Hi, I'm trying to generate some figure with R, into an org
>>>>>> session. Firstly I use the code in the org site. The problem is
>>>>>> that the code do not generate any figure. This is the code:
>>>>>> #+TITLE:Test
>>>>>> #+AUTHOR: Your Name
>>>>>> #+EMAIL: mailto:mailto:your-email@server.com
>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>>>>>>
>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>> ** R text output
>>>>>> A simple summary.
>>>>>> #+begin_src R
>>>>>> x <- rnorm(10)
>>>>>> summary(x)
>>>>>> #+end_src
>>>>>>
>>>>>> ** R graphics output
>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>> =a.png=.
>>>>>>
>>>>>> #+begin_src R :file a.png
>>>>>> y <- rnorm(10)
>>>>>> plot(x, y)
>>>>>> #+end_src
>>>>>>
>>>>>> Same plot with larger dimension:
>>>>>>
>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>> plot(x, y)
>>>>>> #+end_src
>>>>>> Where do I wrong?BestRiccardo
>>>>>
>>>>> <span class="HOEnZb">--
>>>>> Thomas S. Dye
>>>>> http://www.tsdye.com
>>>>> </span>
>
>
> Footnotes:
> [1] http://orgmode.org/worg/org-contrib/babel/languages.html
--
Thomas S. Dye
http://www.tsdye.com
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Updating the Babel section of Worg
2012-02-08 0:01 ` Thomas S. Dye
@ 2012-02-08 1:04 ` Martyn Jago
2012-02-08 14:21 ` Eric Schulte
2012-02-08 14:14 ` Eric Schulte
2012-02-08 15:41 ` John Hendy
2 siblings, 1 reply; 17+ messages in thread
From: Martyn Jago @ 2012-02-08 1:04 UTC (permalink / raw
To: emacs-orgmode
Hi Thomas and Eric
Love it. I will try to help!
Worg is a great resource that is getting better and better.
The template looks good (Babel wise) and should be up there as a
check-sheet, although maybe not as a requirement.
Eric - perhaps mark good pages as good rather than bad pages. They're
not necessarily bad?
It would be cool to say [Tested 2 days ago] at the top of the page
(in a nice green) or something like that. (or validation link in green /
yellow / red)
I also think that [Under development] should be removed from
index.html. Worg is always under development, that's what it is?
For anybody that is not that familiar with Worg, you can contribute to
it right now - it's pure community.
Best, Martyn
tsd@tsdye.com (Thomas S. Dye) writes:
> Hi Eric,
>
> I've attached a first draft of a template for review and revision. It
> is heavily influenced by John Hendy's terrific gnuplot page. I
> believe it incorporates the points in your outline. Feel free to
> edit as appropriate.
>
> All the best,
> Tom
>
>
> #+OPTIONS: H:3 num:nil toc:2 \n:nil @:t ::t |:t ^:{} -:t f:t *:t TeX:t LaTeX:t skip:nil d:(HIDE) tags:not-in-toc
> #+STARTUP: align fold nodlcheck hidestars oddeven lognotestate hideblocks
> #+SEQ_TODO: TODO(t) INPROGRESS(i) WAITING(w@) | DONE(d) CANCELED(c@)
> #+TAGS: Write(w) Update(u) Fix(f) Check(c) noexport(n)
> #+TITLE: Language Source Code Blocks in Org Mode
> #+AUTHOR: Your name
> #+EMAIL: you[at]email[dot]org
> #+LANGUAGE: en
> #+STYLE: <style type="text/css">#outline-container-introduction{ clear:both; }</style>
> #+LINK_UP: ../languages.php
> #+LINK_HOME: http://orgmode.org/worg/
> #+EXPORT_EXCLUDE_TAGS: noexport
>
> #+name: banner
> #+begin_html
> <div id="subtitle" style="float: center; text-align: center;">
> <p>
> Org Mode support for <a href="http://language-site/">Language</a>
> </p>
> <p>
> <a href="http://language-site/">
> <img src="http://language-site/graphic.file"/>
> </a>
> </p>
> </div>
> #+end_html
>
> * Template Checklist [0/13] :noexport:
> - [ ] Revise #+TITLE:
> - [ ] Indicate #+AUTHOR:
> - [ ] Add #+EMAIL:
> - [ ] Revise banner source block [0/3]
> - [ ] Add link to a useful language web site
> - [ ] Replace "Language" with language name
> - [ ] Find a suitable graphic and use it to link to the language
> web site
> - [ ] Write an [[Introduction]]
> - [ ] Describe [[Requirements%20and%20Setup][Requirements and Setup]]
> - [ ] Replace "Language" with language name in [[Org%20Mode%20Features%20for%20Language%20Source%20Code%20Blocks][Org Mode Features for Language Source Code Blocks]]
> - [ ] Specify [[Org%20Mode%20Configuration][Org Mode Configuration]]
> - [ ] Describe [[Header%20Arguments][Header Arguments]]
> - [ ] Describe support for [[Sessions]]
> - [ ] Describe [[Result%20Types][Result Types]]
> - [ ] Describe [[Other]] differences from supported languages
> - [ ] Provide brief [[Examples%20of%20Use][Examples of Use]]
> * Introduction
> - Brief description of language.
> - Range of typical uses within Org Mode.
> - Link to this Org Mode file.
> * Requirements and Setup
> - Installation and configuration of language software
> - Emacs configuration
> * Org Mode Features for Language Source Code Blocks
> ** Org Mode Configuration
> - org-babel-do-load-languages
> ** Header Arguments
> - Language-specific default values
> - Language-specific header arguments
> ** Sessions
> - Support or not
> - Typical use for sessions
> ** Result Types
> - Which result types are supported?
> ** Other
> - Differences from other supported languages
> * Examples of Use
> - Hello World!
> - Common uses
> - Links to tutorials and other resources
>
>
> Eric Schulte <eric.schulte@gmx.com> writes:
>
>> Hi Tom,
>>
>> tsd@tsdye.com (Thomas S. Dye) writes:
>>
>>> Hi Eric,
>>>
>>> Yes, this is overdue. I think your plan is a good one.
>>>
>>> Perhaps a few of the individual use cases could be moved to FIXME,
>>> instead? I'm thinking here of Feiming Chen's R setup and some of my
>>> contributions when I was experimenting writing LaTeX inside source
>>> code blocks. The authors could resurrect these as they see fit.
>>>
>>
>> I don't know what FIXME is, but if there is a way to keep the page in
>> the worg git repository but remove it from the exported HTML then that
>> sounds ideal.
>>
>>>
>>> Hopefully, others will contribute use examples. My sense from reading
>>> the list is there are many interesting ones.
>>>
>>> I'd like it if Org mode users designed a template for the language
>>> specific pages. Currently, these seem to me a mixed bag and it would be
>>> good to regularize them.
>>
>> The below is a modified version of a template which can be found in a
>> couple of the existing language tutorials, I think it serves as a good
>> starting point.
>>
>> - Install and Setup
>> - Instillation and configuration of software (e.g., the language itself)
>> - Configuration of Emacs (e.g., activate language, set command path)
>> - Examples
>> - Common ways to use the language in an Org-mode document
>> - Special cases
>> - are there any language-specific header arguments
>> - does the language support session evaluation
>> - does the language support all result types
>> - is the language different from most babel languages
>> (e.g., C is compiled before execution, ditaa returns files, etc...)
>>
>>> It would also be nice to have one for each of the supported languages.
>>> There are 11 language specific pages now, which leaves quite a few
>>> languages under-documented.
>>
>> (length org-babel-load-languages) ;; => 27
>>
>> ls org-contrib/babel/languages/ob-doc-*|wc -l # => 11
>>
>> It looks like we have at least 16 more to go before we hit full language
>> coverage. Perhaps we should use the empty cells in the "documentation"
>> column in the languages table at [1] as a sign up space for volunteers
>> who would be willing to write a brief tutorial demonstrating usage of
>> Org-mode with their favorite language.
>>
>> Moving forward this is likely something we could request of the
>> contributors of new languages.
>>
>> Also, once the template above is finalized it should be posted on worg
>> and linked to through the languages page.
>>
>>>
>>> I'll be happy to work on this as I can.
>>>
>>
>> Great, I don't anticipate having time to put towards this, although I'll
>> be happy to help troubleshoot where I can.
>>
>> Cheers,
>>
>>>
>>> All the best,
>>> Tom
>>>
>>>
>>> Eric Schulte <eric.schulte@gmx.com> writes:
>>>
>>>> Thanks for raising this point. The bulk of the content in the Babel
>>>> portion of worg is fairly old, predating the syntax standardization
>>>> efforts this fall. I've just pushed some minor updates to the main
>>>> babel pages, but updating the language-specific tutorials and the
>>>> individual use cases will be a much larger effort.
>>>>
>>>> I'm not sure how to proceed. One option would be to go through and add
>>>> a [uses deprecated syntax] tag to the top of each such page, which could
>>>> be removed after the page has been checked and possibly updated to
>>>> ensure consistency with the latest syntax.
>>>>
>>>> Given that the Babel syntax will not be changing significantly moving
>>>> forward now would be a good time to do such a review. Ideally this
>>>> could be completed before the release of Emacs 24 in a couple of months.
>>>>
>>>> Any other ideas for update/reorganization or volunteers?
>>>>
>>>> Cheers,
>>>>
>>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>>
>>>>> Hi Riccardo,
>>>>>
>>>>> Thanks for the URL. Org mode has evolved since this article was
>>>>> written. It should probably be revised or taken off Worg. I've copied
>>>>> Eric Schulte, who is better able than me to determine the correct course
>>>>> of action here.
>>>>>
>>>>> In the meantime, an up-to-date description of how Org mode can be used
>>>>> to write literate programs has appeared in the Journal of Statistical
>>>>> Software. You can find it here: http://www.jstatsoft.org/v46/i03
>>>>>
>>>>> Perhaps you could use the examples in the JSS article to get started?
>>>>> If these don't work for you, or if they raise questions that are difficult
>>>>> to answer, please do come back to the list with your queries.
>>>>>
>>>>> All the best,
>>>>> Tom
>>>>>
>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>
>>>>>> Hi, this is the URL:
>>>>>>
>>>>>> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>>>>>>
>>>>>> Best
>>>>>> R
>>>>>>
>>>>>> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>>>>>>
>>>>>>> Hi Riccardo,
>>>>>>>
>>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>>> site. Could you send a URL?
>>>>>>>
>>>>>>> All the best,
>>>>>>> Tom
>>>>>>>
>>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>>
>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>> Firstly
>>>>>>> > I use the code in the org site. The problem is that the code do not
>>>>>>> > generate any figure.
>>>>>>> >
>>>>>>> > This is the code:
>>>>>>> >
>>>>>>> > #+TITLE:Test
>>>>>>> > #+AUTHOR: Your Name
>>>>>>> > #+EMAIL: your-email@server.com
>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>> > both :tangle yes
>>>>>>> >
>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>> > ** R text output
>>>>>>> > A simple summary.
>>>>>>> > #+begin_src R
>>>>>>> > x <- rnorm(10)
>>>>>>> > summary(x)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > ** R graphics output
>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>> > =a.png=.
>>>>>>> >
>>>>>>> > #+begin_src R :file a.png
>>>>>>> > y <- rnorm(10)
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > Same plot with larger dimension:
>>>>>>> >
>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> >
>>>>>>> > Where do I wrong?
>>>>>>> >
>>>>>>> > Best
>>>>>>> > Riccardo
>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>> Firstly I use the code in the org site. The problem is that the code do not
>>>>>>> generate any figure. This is the code:
>>>>>>> > #+TITLE:Test
>>>>>>> > #+AUTHOR: Your Name
>>>>>>> > #+EMAIL: mailto:your-email@server.com
>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
>>>>>>> :tangle yes
>>>>>>> >
>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>> > ** R text output
>>>>>>> > A simple summary.
>>>>>>> > #+begin_src R
>>>>>>> > x <- rnorm(10)
>>>>>>> > summary(x)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > ** R graphics output
>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>> > =a.png=.
>>>>>>> >
>>>>>>> > #+begin_src R :file a.png
>>>>>>> > y <- rnorm(10)
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > Same plot with larger dimension:
>>>>>>> >
>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> > Where do I wrong?BestRiccardo
>>>>>>>
>>>>>>> --
>>>>>>> Thomas S. Dye
>>>>>>> http://www.tsdye.com
>>>>>>>
>>>>>> Hi, this is the URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
>>>>>> 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi Riccardo,
>>>>>>
>>>>>>
>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>> site. Could you send a URL?
>>>>>>
>>>>>> All the best,
>>>>>> Tom
>>>>>>
>>>>>> Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
>>>>>>
>>>>>>> Hi, I'm trying to generate some figure with R, into an org session. Firstly
>>>>>>> I use the code in the org site. The problem is that the code do not
>>>>>>> generate any figure.
>>>>>>>
>>>>>>> This is the code:
>>>>>>>
>>>>>>> #+TITLE:Test
>>>>>>> #+AUTHOR: Your Name
>>>>>>> #+EMAIL: mailto:your-email@server.com
>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>> both :tangle yes
>>>>>>>
>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>> ** R text output
>>>>>>> A simple summary.
>>>>>>> #+begin_src R
>>>>>>> x <- rnorm(10)
>>>>>>> summary(x)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> ** R graphics output
>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>> =a.png=.
>>>>>>>
>>>>>>> #+begin_src R :file a.png
>>>>>>> y <- rnorm(10)
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> Same plot with larger dimension:
>>>>>>>
>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>>
>>>>>>>
>>>>>>> Where do I wrong?
>>>>>>>
>>>>>>> Best
>>>>>>> Riccardo
>>>>>>> Hi, I'm trying to generate some figure with R, into an org
>>>>>>> session. Firstly I use the code in the org site. The problem is
>>>>>>> that the code do not generate any figure. This is the code:
>>>>>>> #+TITLE:Test
>>>>>>> #+AUTHOR: Your Name
>>>>>>> #+EMAIL: mailto:mailto:your-email@server.com
>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>>>>>>>
>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>> ** R text output
>>>>>>> A simple summary.
>>>>>>> #+begin_src R
>>>>>>> x <- rnorm(10)
>>>>>>> summary(x)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> ** R graphics output
>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>> =a.png=.
>>>>>>>
>>>>>>> #+begin_src R :file a.png
>>>>>>> y <- rnorm(10)
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> Same plot with larger dimension:
>>>>>>>
>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>> Where do I wrong?BestRiccardo
>>>>>>
>>>>>> <span class="HOEnZb">--
>>>>>> Thomas S. Dye
>>>>>> http://www.tsdye.com
>>>>>> </span>
>>
>>
>> Footnotes:
>> [1] http://orgmode.org/worg/org-contrib/babel/languages.html
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Updating the Babel section of Worg
2012-02-08 0:01 ` Thomas S. Dye
2012-02-08 1:04 ` Martyn Jago
@ 2012-02-08 14:14 ` Eric Schulte
2012-02-09 17:20 ` Thomas S. Dye
2012-02-08 15:41 ` John Hendy
2 siblings, 1 reply; 17+ messages in thread
From: Eric Schulte @ 2012-02-08 14:14 UTC (permalink / raw
To: Thomas S. Dye; +Cc: emacs-orgmode, Riccardo Romoli
tsd@tsdye.com (Thomas S. Dye) writes:
> Hi Eric,
>
> I've attached a first draft of a template for review and revision. It
> is heavily influenced by John Hendy's terrific gnuplot page. I
> believe it incorporates the points in your outline. Feel free to
> edit as appropriate.
>
Looks great to me. I made a small change, and I've just pushed it up to
worg and linked to it from the languages page. We can continue to
improve this template as needed on worg although I think it is already
in very good shape and ready for use.
Thanks,
>
> All the best,
> Tom
>
>
>
>
> Eric Schulte <eric.schulte@gmx.com> writes:
>
>> Hi Tom,
>>
>> tsd@tsdye.com (Thomas S. Dye) writes:
>>
>>> Hi Eric,
>>>
>>> Yes, this is overdue. I think your plan is a good one.
>>>
>>> Perhaps a few of the individual use cases could be moved to FIXME,
>>> instead? I'm thinking here of Feiming Chen's R setup and some of my
>>> contributions when I was experimenting writing LaTeX inside source
>>> code blocks. The authors could resurrect these as they see fit.
>>>
>>
>> I don't know what FIXME is, but if there is a way to keep the page in
>> the worg git repository but remove it from the exported HTML then that
>> sounds ideal.
>>
>>>
>>> Hopefully, others will contribute use examples. My sense from reading
>>> the list is there are many interesting ones.
>>>
>>> I'd like it if Org mode users designed a template for the language
>>> specific pages. Currently, these seem to me a mixed bag and it would be
>>> good to regularize them.
>>
>> The below is a modified version of a template which can be found in a
>> couple of the existing language tutorials, I think it serves as a good
>> starting point.
>>
>> - Install and Setup
>> - Instillation and configuration of software (e.g., the language itself)
>> - Configuration of Emacs (e.g., activate language, set command path)
>> - Examples
>> - Common ways to use the language in an Org-mode document
>> - Special cases
>> - are there any language-specific header arguments
>> - does the language support session evaluation
>> - does the language support all result types
>> - is the language different from most babel languages
>> (e.g., C is compiled before execution, ditaa returns files, etc...)
>>
>>> It would also be nice to have one for each of the supported languages.
>>> There are 11 language specific pages now, which leaves quite a few
>>> languages under-documented.
>>
>> (length org-babel-load-languages) ;; => 27
>>
>> ls org-contrib/babel/languages/ob-doc-*|wc -l # => 11
>>
>> It looks like we have at least 16 more to go before we hit full language
>> coverage. Perhaps we should use the empty cells in the "documentation"
>> column in the languages table at [1] as a sign up space for volunteers
>> who would be willing to write a brief tutorial demonstrating usage of
>> Org-mode with their favorite language.
>>
>> Moving forward this is likely something we could request of the
>> contributors of new languages.
>>
>> Also, once the template above is finalized it should be posted on worg
>> and linked to through the languages page.
>>
>>>
>>> I'll be happy to work on this as I can.
>>>
>>
>> Great, I don't anticipate having time to put towards this, although I'll
>> be happy to help troubleshoot where I can.
>>
>> Cheers,
>>
>>>
>>> All the best,
>>> Tom
>>>
>>>
>>> Eric Schulte <eric.schulte@gmx.com> writes:
>>>
>>>> Thanks for raising this point. The bulk of the content in the Babel
>>>> portion of worg is fairly old, predating the syntax standardization
>>>> efforts this fall. I've just pushed some minor updates to the main
>>>> babel pages, but updating the language-specific tutorials and the
>>>> individual use cases will be a much larger effort.
>>>>
>>>> I'm not sure how to proceed. One option would be to go through and add
>>>> a [uses deprecated syntax] tag to the top of each such page, which could
>>>> be removed after the page has been checked and possibly updated to
>>>> ensure consistency with the latest syntax.
>>>>
>>>> Given that the Babel syntax will not be changing significantly moving
>>>> forward now would be a good time to do such a review. Ideally this
>>>> could be completed before the release of Emacs 24 in a couple of months.
>>>>
>>>> Any other ideas for update/reorganization or volunteers?
>>>>
>>>> Cheers,
>>>>
>>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>>
>>>>> Hi Riccardo,
>>>>>
>>>>> Thanks for the URL. Org mode has evolved since this article was
>>>>> written. It should probably be revised or taken off Worg. I've copied
>>>>> Eric Schulte, who is better able than me to determine the correct course
>>>>> of action here.
>>>>>
>>>>> In the meantime, an up-to-date description of how Org mode can be used
>>>>> to write literate programs has appeared in the Journal of Statistical
>>>>> Software. You can find it here: http://www.jstatsoft.org/v46/i03
>>>>>
>>>>> Perhaps you could use the examples in the JSS article to get started?
>>>>> If these don't work for you, or if they raise questions that are difficult
>>>>> to answer, please do come back to the list with your queries.
>>>>>
>>>>> All the best,
>>>>> Tom
>>>>>
>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>
>>>>>> Hi, this is the URL:
>>>>>>
>>>>>> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>>>>>>
>>>>>> Best
>>>>>> R
>>>>>>
>>>>>> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>>>>>>
>>>>>>> Hi Riccardo,
>>>>>>>
>>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>>> site. Could you send a URL?
>>>>>>>
>>>>>>> All the best,
>>>>>>> Tom
>>>>>>>
>>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>>
>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>> Firstly
>>>>>>> > I use the code in the org site. The problem is that the code do not
>>>>>>> > generate any figure.
>>>>>>> >
>>>>>>> > This is the code:
>>>>>>> >
>>>>>>> > #+TITLE:Test
>>>>>>> > #+AUTHOR: Your Name
>>>>>>> > #+EMAIL: your-email@server.com
>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>> > both :tangle yes
>>>>>>> >
>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>> > ** R text output
>>>>>>> > A simple summary.
>>>>>>> > #+begin_src R
>>>>>>> > x <- rnorm(10)
>>>>>>> > summary(x)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > ** R graphics output
>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>> > =a.png=.
>>>>>>> >
>>>>>>> > #+begin_src R :file a.png
>>>>>>> > y <- rnorm(10)
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > Same plot with larger dimension:
>>>>>>> >
>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> >
>>>>>>> > Where do I wrong?
>>>>>>> >
>>>>>>> > Best
>>>>>>> > Riccardo
>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>> Firstly I use the code in the org site. The problem is that the code do not
>>>>>>> generate any figure. This is the code:
>>>>>>> > #+TITLE:Test
>>>>>>> > #+AUTHOR: Your Name
>>>>>>> > #+EMAIL: mailto:your-email@server.com
>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
>>>>>>> :tangle yes
>>>>>>> >
>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>> > ** R text output
>>>>>>> > A simple summary.
>>>>>>> > #+begin_src R
>>>>>>> > x <- rnorm(10)
>>>>>>> > summary(x)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > ** R graphics output
>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>> > =a.png=.
>>>>>>> >
>>>>>>> > #+begin_src R :file a.png
>>>>>>> > y <- rnorm(10)
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > Same plot with larger dimension:
>>>>>>> >
>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> > Where do I wrong?BestRiccardo
>>>>>>>
>>>>>>> --
>>>>>>> Thomas S. Dye
>>>>>>> http://www.tsdye.com
>>>>>>>
>>>>>> Hi, this is the URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
>>>>>> 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi Riccardo,
>>>>>>
>>>>>>
>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>> site. Could you send a URL?
>>>>>>
>>>>>> All the best,
>>>>>> Tom
>>>>>>
>>>>>> Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
>>>>>>
>>>>>>> Hi, I'm trying to generate some figure with R, into an org session. Firstly
>>>>>>> I use the code in the org site. The problem is that the code do not
>>>>>>> generate any figure.
>>>>>>>
>>>>>>> This is the code:
>>>>>>>
>>>>>>> #+TITLE:Test
>>>>>>> #+AUTHOR: Your Name
>>>>>>> #+EMAIL: mailto:your-email@server.com
>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>> both :tangle yes
>>>>>>>
>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>> ** R text output
>>>>>>> A simple summary.
>>>>>>> #+begin_src R
>>>>>>> x <- rnorm(10)
>>>>>>> summary(x)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> ** R graphics output
>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>> =a.png=.
>>>>>>>
>>>>>>> #+begin_src R :file a.png
>>>>>>> y <- rnorm(10)
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> Same plot with larger dimension:
>>>>>>>
>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>>
>>>>>>>
>>>>>>> Where do I wrong?
>>>>>>>
>>>>>>> Best
>>>>>>> Riccardo
>>>>>>> Hi, I'm trying to generate some figure with R, into an org
>>>>>>> session. Firstly I use the code in the org site. The problem is
>>>>>>> that the code do not generate any figure. This is the code:
>>>>>>> #+TITLE:Test
>>>>>>> #+AUTHOR: Your Name
>>>>>>> #+EMAIL: mailto:mailto:your-email@server.com
>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>>>>>>>
>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>> ** R text output
>>>>>>> A simple summary.
>>>>>>> #+begin_src R
>>>>>>> x <- rnorm(10)
>>>>>>> summary(x)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> ** R graphics output
>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>> =a.png=.
>>>>>>>
>>>>>>> #+begin_src R :file a.png
>>>>>>> y <- rnorm(10)
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> Same plot with larger dimension:
>>>>>>>
>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>> Where do I wrong?BestRiccardo
>>>>>>
>>>>>> <span class="HOEnZb">--
>>>>>> Thomas S. Dye
>>>>>> http://www.tsdye.com
>>>>>> </span>
>>
>>
>> Footnotes:
>> [1] http://orgmode.org/worg/org-contrib/babel/languages.html
--
Eric Schulte
http://cs.unm.edu/~eschulte/
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Updating the Babel section of Worg
2012-02-08 1:04 ` Martyn Jago
@ 2012-02-08 14:21 ` Eric Schulte
2012-02-08 14:44 ` Rainer M Krug
0 siblings, 1 reply; 17+ messages in thread
From: Eric Schulte @ 2012-02-08 14:21 UTC (permalink / raw
To: Martyn Jago; +Cc: emacs-orgmode
Martyn Jago <martyn.jago@btinternet.com> writes:
> Hi Thomas and Eric
>
> Love it. I will try to help!
>
> Worg is a great resource that is getting better and better.
>
> The template looks good (Babel wise) and should be up there as a
> check-sheet, although maybe not as a requirement.
>
I agree, I've just linked to it from the languages page [1] with the
following statement. Please feel free to edit this directly on worg if
it sounds too strong.
Note: Many languages in this table still require documentation. A
template is provided in the worg git repository for the addition of
language documentation.
>
> Eric - perhaps mark good pages as good rather than bad pages. They're
> not necessarily bad?
>
I agree, I don't think any of the pages are "bad". Rather some pages
simply need to be updated to use the new standard syntax. In this case
I would find it better to simply flag those pages which need to be
updated, rather than litter all pages with tags.
>
> It would be cool to say [Tested 2 days ago] at the top of the page
> (in a nice green) or something like that. (or validation link in green /
> yellow / red)
>
I see you point, but the plan is that after this falls syntax
standardization we should not be making any breaking changes moving
forward, so a page from Dec 2011 should be as valid as a page from Jan
2013.
>
> I also think that [Under development] should be removed from
> index.html. Worg is always under development, that's what it is?
>
I agree.
>
> For anybody that is not that familiar with Worg, you can contribute to
> it right now - it's pure community.
>
^
well said! |
Cheers,
>
> Best, Martyn
>
> tsd@tsdye.com (Thomas S. Dye) writes:
>
>> Hi Eric,
>>
>> I've attached a first draft of a template for review and revision. It
>> is heavily influenced by John Hendy's terrific gnuplot page. I
>> believe it incorporates the points in your outline. Feel free to
>> edit as appropriate.
>>
>> All the best,
>> Tom
>>
>>
>> #+OPTIONS: H:3 num:nil toc:2 \n:nil @:t ::t |:t ^:{} -:t f:t *:t TeX:t LaTeX:t skip:nil d:(HIDE) tags:not-in-toc
>> #+STARTUP: align fold nodlcheck hidestars oddeven lognotestate hideblocks
>> #+SEQ_TODO: TODO(t) INPROGRESS(i) WAITING(w@) | DONE(d) CANCELED(c@)
>> #+TAGS: Write(w) Update(u) Fix(f) Check(c) noexport(n)
>> #+TITLE: Language Source Code Blocks in Org Mode
>> #+AUTHOR: Your name
>> #+EMAIL: you[at]email[dot]org
>> #+LANGUAGE: en
>> #+STYLE: <style type="text/css">#outline-container-introduction{ clear:both; }</style>
>> #+LINK_UP: ../languages.php
>> #+LINK_HOME: http://orgmode.org/worg/
>> #+EXPORT_EXCLUDE_TAGS: noexport
>>
>> #+name: banner
>> #+begin_html
>> <div id="subtitle" style="float: center; text-align: center;">
>> <p>
>> Org Mode support for <a href="http://language-site/">Language</a>
>> </p>
>> <p>
>> <a href="http://language-site/">
>> <img src="http://language-site/graphic.file"/>
>> </a>
>> </p>
>> </div>
>> #+end_html
>>
>> * Template Checklist [0/13] :noexport:
>> - [ ] Revise #+TITLE:
>> - [ ] Indicate #+AUTHOR:
>> - [ ] Add #+EMAIL:
>> - [ ] Revise banner source block [0/3]
>> - [ ] Add link to a useful language web site
>> - [ ] Replace "Language" with language name
>> - [ ] Find a suitable graphic and use it to link to the language
>> web site
>> - [ ] Write an [[Introduction]]
>> - [ ] Describe [[Requirements%20and%20Setup][Requirements and Setup]]
>> - [ ] Replace "Language" with language name in [[Org%20Mode%20Features%20for%20Language%20Source%20Code%20Blocks][Org Mode Features for Language Source Code Blocks]]
>> - [ ] Specify [[Org%20Mode%20Configuration][Org Mode Configuration]]
>> - [ ] Describe [[Header%20Arguments][Header Arguments]]
>> - [ ] Describe support for [[Sessions]]
>> - [ ] Describe [[Result%20Types][Result Types]]
>> - [ ] Describe [[Other]] differences from supported languages
>> - [ ] Provide brief [[Examples%20of%20Use][Examples of Use]]
>> * Introduction
>> - Brief description of language.
>> - Range of typical uses within Org Mode.
>> - Link to this Org Mode file.
>> * Requirements and Setup
>> - Installation and configuration of language software
>> - Emacs configuration
>> * Org Mode Features for Language Source Code Blocks
>> ** Org Mode Configuration
>> - org-babel-do-load-languages
>> ** Header Arguments
>> - Language-specific default values
>> - Language-specific header arguments
>> ** Sessions
>> - Support or not
>> - Typical use for sessions
>> ** Result Types
>> - Which result types are supported?
>> ** Other
>> - Differences from other supported languages
>> * Examples of Use
>> - Hello World!
>> - Common uses
>> - Links to tutorials and other resources
>>
>>
>> Eric Schulte <eric.schulte@gmx.com> writes:
>>
>>> Hi Tom,
>>>
>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>
>>>> Hi Eric,
>>>>
>>>> Yes, this is overdue. I think your plan is a good one.
>>>>
>>>> Perhaps a few of the individual use cases could be moved to FIXME,
>>>> instead? I'm thinking here of Feiming Chen's R setup and some of my
>>>> contributions when I was experimenting writing LaTeX inside source
>>>> code blocks. The authors could resurrect these as they see fit.
>>>>
>>>
>>> I don't know what FIXME is, but if there is a way to keep the page in
>>> the worg git repository but remove it from the exported HTML then that
>>> sounds ideal.
>>>
>>>>
>>>> Hopefully, others will contribute use examples. My sense from reading
>>>> the list is there are many interesting ones.
>>>>
>>>> I'd like it if Org mode users designed a template for the language
>>>> specific pages. Currently, these seem to me a mixed bag and it would be
>>>> good to regularize them.
>>>
>>> The below is a modified version of a template which can be found in a
>>> couple of the existing language tutorials, I think it serves as a good
>>> starting point.
>>>
>>> - Install and Setup
>>> - Instillation and configuration of software (e.g., the language itself)
>>> - Configuration of Emacs (e.g., activate language, set command path)
>>> - Examples
>>> - Common ways to use the language in an Org-mode document
>>> - Special cases
>>> - are there any language-specific header arguments
>>> - does the language support session evaluation
>>> - does the language support all result types
>>> - is the language different from most babel languages
>>> (e.g., C is compiled before execution, ditaa returns files, etc...)
>>>
>>>> It would also be nice to have one for each of the supported languages.
>>>> There are 11 language specific pages now, which leaves quite a few
>>>> languages under-documented.
>>>
>>> (length org-babel-load-languages) ;; => 27
>>>
>>> ls org-contrib/babel/languages/ob-doc-*|wc -l # => 11
>>>
>>> It looks like we have at least 16 more to go before we hit full language
>>> coverage. Perhaps we should use the empty cells in the "documentation"
>>> column in the languages table at [1] as a sign up space for volunteers
>>> who would be willing to write a brief tutorial demonstrating usage of
>>> Org-mode with their favorite language.
>>>
>>> Moving forward this is likely something we could request of the
>>> contributors of new languages.
>>>
>>> Also, once the template above is finalized it should be posted on worg
>>> and linked to through the languages page.
>>>
>>>>
>>>> I'll be happy to work on this as I can.
>>>>
>>>
>>> Great, I don't anticipate having time to put towards this, although I'll
>>> be happy to help troubleshoot where I can.
>>>
>>> Cheers,
>>>
>>>>
>>>> All the best,
>>>> Tom
>>>>
>>>>
>>>> Eric Schulte <eric.schulte@gmx.com> writes:
>>>>
>>>>> Thanks for raising this point. The bulk of the content in the Babel
>>>>> portion of worg is fairly old, predating the syntax standardization
>>>>> efforts this fall. I've just pushed some minor updates to the main
>>>>> babel pages, but updating the language-specific tutorials and the
>>>>> individual use cases will be a much larger effort.
>>>>>
>>>>> I'm not sure how to proceed. One option would be to go through and add
>>>>> a [uses deprecated syntax] tag to the top of each such page, which could
>>>>> be removed after the page has been checked and possibly updated to
>>>>> ensure consistency with the latest syntax.
>>>>>
>>>>> Given that the Babel syntax will not be changing significantly moving
>>>>> forward now would be a good time to do such a review. Ideally this
>>>>> could be completed before the release of Emacs 24 in a couple of months.
>>>>>
>>>>> Any other ideas for update/reorganization or volunteers?
>>>>>
>>>>> Cheers,
>>>>>
>>>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>>>
>>>>>> Hi Riccardo,
>>>>>>
>>>>>> Thanks for the URL. Org mode has evolved since this article was
>>>>>> written. It should probably be revised or taken off Worg. I've copied
>>>>>> Eric Schulte, who is better able than me to determine the correct course
>>>>>> of action here.
>>>>>>
>>>>>> In the meantime, an up-to-date description of how Org mode can be used
>>>>>> to write literate programs has appeared in the Journal of Statistical
>>>>>> Software. You can find it here: http://www.jstatsoft.org/v46/i03
>>>>>>
>>>>>> Perhaps you could use the examples in the JSS article to get started?
>>>>>> If these don't work for you, or if they raise questions that are difficult
>>>>>> to answer, please do come back to the list with your queries.
>>>>>>
>>>>>> All the best,
>>>>>> Tom
>>>>>>
>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>
>>>>>>> Hi, this is the URL:
>>>>>>>
>>>>>>> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>>>>>>>
>>>>>>> Best
>>>>>>> R
>>>>>>>
>>>>>>> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>>>>>>>
>>>>>>>> Hi Riccardo,
>>>>>>>>
>>>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>>>> site. Could you send a URL?
>>>>>>>>
>>>>>>>> All the best,
>>>>>>>> Tom
>>>>>>>>
>>>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>>>
>>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>>> Firstly
>>>>>>>> > I use the code in the org site. The problem is that the code do not
>>>>>>>> > generate any figure.
>>>>>>>> >
>>>>>>>> > This is the code:
>>>>>>>> >
>>>>>>>> > #+TITLE:Test
>>>>>>>> > #+AUTHOR: Your Name
>>>>>>>> > #+EMAIL: your-email@server.com
>>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>>> > both :tangle yes
>>>>>>>> >
>>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>>> > ** R text output
>>>>>>>> > A simple summary.
>>>>>>>> > #+begin_src R
>>>>>>>> > x <- rnorm(10)
>>>>>>>> > summary(x)
>>>>>>>> > #+end_src
>>>>>>>> >
>>>>>>>> > ** R graphics output
>>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>>> > =a.png=.
>>>>>>>> >
>>>>>>>> > #+begin_src R :file a.png
>>>>>>>> > y <- rnorm(10)
>>>>>>>> > plot(x, y)
>>>>>>>> > #+end_src
>>>>>>>> >
>>>>>>>> > Same plot with larger dimension:
>>>>>>>> >
>>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>>> > plot(x, y)
>>>>>>>> > #+end_src
>>>>>>>> >
>>>>>>>> >
>>>>>>>> > Where do I wrong?
>>>>>>>> >
>>>>>>>> > Best
>>>>>>>> > Riccardo
>>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>>> Firstly I use the code in the org site. The problem is that the code do not
>>>>>>>> generate any figure. This is the code:
>>>>>>>> > #+TITLE:Test
>>>>>>>> > #+AUTHOR: Your Name
>>>>>>>> > #+EMAIL: mailto:your-email@server.com
>>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
>>>>>>>> :tangle yes
>>>>>>>> >
>>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>>> > ** R text output
>>>>>>>> > A simple summary.
>>>>>>>> > #+begin_src R
>>>>>>>> > x <- rnorm(10)
>>>>>>>> > summary(x)
>>>>>>>> > #+end_src
>>>>>>>> >
>>>>>>>> > ** R graphics output
>>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>>> > =a.png=.
>>>>>>>> >
>>>>>>>> > #+begin_src R :file a.png
>>>>>>>> > y <- rnorm(10)
>>>>>>>> > plot(x, y)
>>>>>>>> > #+end_src
>>>>>>>> >
>>>>>>>> > Same plot with larger dimension:
>>>>>>>> >
>>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>>> > plot(x, y)
>>>>>>>> > #+end_src
>>>>>>>> > Where do I wrong?BestRiccardo
>>>>>>>>
>>>>>>>> --
>>>>>>>> Thomas S. Dye
>>>>>>>> http://www.tsdye.com
>>>>>>>>
>>>>>>> Hi, this is the
>>>>>>> URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
>>>>>>> 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi Riccardo,
>>>>>>>
>>>>>>>
>>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>>> site. Could you send a URL?
>>>>>>>
>>>>>>> All the best,
>>>>>>> Tom
>>>>>>>
>>>>>>> Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
>>>>>>>
>>>>>>>> Hi, I'm trying to generate some figure with R, into an org session. Firstly
>>>>>>>> I use the code in the org site. The problem is that the code do not
>>>>>>>> generate any figure.
>>>>>>>>
>>>>>>>> This is the code:
>>>>>>>>
>>>>>>>> #+TITLE:Test
>>>>>>>> #+AUTHOR: Your Name
>>>>>>>> #+EMAIL: mailto:your-email@server.com
>>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>>> both :tangle yes
>>>>>>>>
>>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>>> ** R text output
>>>>>>>> A simple summary.
>>>>>>>> #+begin_src R
>>>>>>>> x <- rnorm(10)
>>>>>>>> summary(x)
>>>>>>>> #+end_src
>>>>>>>>
>>>>>>>> ** R graphics output
>>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>>> =a.png=.
>>>>>>>>
>>>>>>>> #+begin_src R :file a.png
>>>>>>>> y <- rnorm(10)
>>>>>>>> plot(x, y)
>>>>>>>> #+end_src
>>>>>>>>
>>>>>>>> Same plot with larger dimension:
>>>>>>>>
>>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>>> plot(x, y)
>>>>>>>> #+end_src
>>>>>>>>
>>>>>>>>
>>>>>>>> Where do I wrong?
>>>>>>>>
>>>>>>>> Best
>>>>>>>> Riccardo
>>>>>>>> Hi, I'm trying to generate some figure with R, into an org
>>>>>>>> session. Firstly I use the code in the org site. The problem is
>>>>>>>> that the code do not generate any figure. This is the code:
>>>>>>>> #+TITLE:Test
>>>>>>>> #+AUTHOR: Your Name
>>>>>>>> #+EMAIL: mailto:mailto:your-email@server.com
>>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>>>>>>>>
>>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>>> ** R text output
>>>>>>>> A simple summary.
>>>>>>>> #+begin_src R
>>>>>>>> x <- rnorm(10)
>>>>>>>> summary(x)
>>>>>>>> #+end_src
>>>>>>>>
>>>>>>>> ** R graphics output
>>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>>> =a.png=.
>>>>>>>>
>>>>>>>> #+begin_src R :file a.png
>>>>>>>> y <- rnorm(10)
>>>>>>>> plot(x, y)
>>>>>>>> #+end_src
>>>>>>>>
>>>>>>>> Same plot with larger dimension:
>>>>>>>>
>>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>>> plot(x, y)
>>>>>>>> #+end_src
>>>>>>>> Where do I wrong?BestRiccardo
>>>>>>>
>>>>>>> <span class="HOEnZb">--
>>>>>>> Thomas S. Dye
>>>>>>> http://www.tsdye.com
>>>>>>> </span>
>>>
>>>
>>> Footnotes:
>>> [1] http://orgmode.org/worg/org-contrib/babel/languages.html
>
>
Footnotes:
[1] http://orgmode.org/worg/org-contrib/babel/languages.html
--
Eric Schulte
http://cs.unm.edu/~eschulte/
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Updating the Babel section of Worg
2012-02-08 14:21 ` Eric Schulte
@ 2012-02-08 14:44 ` Rainer M Krug
2012-02-08 15:27 ` Eric Schulte
0 siblings, 1 reply; 17+ messages in thread
From: Rainer M Krug @ 2012-02-08 14:44 UTC (permalink / raw
To: Eric Schulte; +Cc: Martyn Jago, emacs-orgmode
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 08/02/12 15:21, Eric Schulte wrote:
> Martyn Jago <martyn.jago@btinternet.com> writes:
>
>> Hi Thomas and Eric
>>
>> Love it. I will try to help!
>>
>> Worg is a great resource that is getting better and better.
>>
>> The template looks good (Babel wise) and should be up there as a
>> check-sheet, although maybe not as a requirement.
>>
>
> I agree, I've just linked to it from the languages page [1] with
> the following statement. Please feel free to edit this directly on
> worg if it sounds too strong.
Nice - I will take a look at it.
Just to make it easier for non-regular worg contributors: I would
suggest to give an email where one can send the completed template to
to be submitted to worg.
Rainer
>
> Note: Many languages in this table still require documentation. A
> template is provided in the worg git repository for the addition
> of language documentation.
>
>>
>> Eric - perhaps mark good pages as good rather than bad pages.
>> They're not necessarily bad?
>>
>
> I agree, I don't think any of the pages are "bad". Rather some
> pages simply need to be updated to use the new standard syntax. In
> this case I would find it better to simply flag those pages which
> need to be updated, rather than litter all pages with tags.
>
>>
>> It would be cool to say [Tested 2 days ago] at the top of the
>> page (in a nice green) or something like that. (or validation
>> link in green / yellow / red)
>>
>
> I see you point, but the plan is that after this falls syntax
> standardization we should not be making any breaking changes
> moving forward, so a page from Dec 2011 should be as valid as a
> page from Jan 2013.
>
>>
>> I also think that [Under development] should be removed from
>> index.html. Worg is always under development, that's what it is?
>>
>
> I agree.
>
>>
>> For anybody that is not that familiar with Worg, you can
>> contribute to it right now - it's pure community.
>>
> ^ well said! |
>
> Cheers,
>
>>
>> Best, Martyn
>>
>> tsd@tsdye.com (Thomas S. Dye) writes:
>>
>>> Hi Eric,
>>>
>>> I've attached a first draft of a template for review and
>>> revision. It is heavily influenced by John Hendy's terrific
>>> gnuplot page. I believe it incorporates the points in your
>>> outline. Feel free to edit as appropriate.
>>>
>>> All the best, Tom
>>>
>>>
>>> #+OPTIONS: H:3 num:nil toc:2 \n:nil @:t ::t |:t ^:{} -:t f:t
>>> *:t TeX:t LaTeX:t skip:nil d:(HIDE) tags:not-in-toc #+STARTUP:
>>> align fold nodlcheck hidestars oddeven lognotestate hideblocks
>>> #+SEQ_TODO: TODO(t) INPROGRESS(i) WAITING(w@) | DONE(d)
>>> CANCELED(c@) #+TAGS: Write(w) Update(u) Fix(f) Check(c)
>>> noexport(n) #+TITLE: Language Source Code Blocks in Org
>>> Mode #+AUTHOR: Your name #+EMAIL:
>>> you[at]email[dot]org #+LANGUAGE: en #+STYLE: <style
>>> type="text/css">#outline-container-introduction{ clear:both;
>>> }</style> #+LINK_UP: ../languages.php #+LINK_HOME:
>>> http://orgmode.org/worg/ #+EXPORT_EXCLUDE_TAGS: noexport
>>>
>>> #+name: banner #+begin_html <div id="subtitle" style="float:
>>> center; text-align: center;"> <p> Org Mode support for <a
>>> href="http://language-site/">Language</a> </p> <p> <a
>>> href="http://language-site/"> <img
>>> src="http://language-site/graphic.file"/> </a> </p> </div>
>>> #+end_html
>>>
>>> * Template Checklist [0/13]
>>> :noexport: - [ ] Revise #+TITLE: - [ ] Indicate #+AUTHOR: - [ ]
>>> Add #+EMAIL: - [ ] Revise banner source block [0/3] - [ ] Add
>>> link to a useful language web site - [ ] Replace "Language"
>>> with language name - [ ] Find a suitable graphic and use it to
>>> link to the language web site - [ ] Write an [[Introduction]] -
>>> [ ] Describe [[Requirements%20and%20Setup][Requirements and
>>> Setup]] - [ ] Replace "Language" with language name in
>>> [[Org%20Mode%20Features%20for%20Language%20Source%20Code%20Blocks][Org
>>> Mode Features for Language Source Code Blocks]] - [ ] Specify
>>> [[Org%20Mode%20Configuration][Org Mode Configuration]] - [ ]
>>> Describe [[Header%20Arguments][Header Arguments]] - [ ]
>>> Describe support for [[Sessions]] - [ ] Describe
>>> [[Result%20Types][Result Types]] - [ ] Describe [[Other]]
>>> differences from supported languages - [ ] Provide brief
>>> [[Examples%20of%20Use][Examples of Use]] * Introduction - Brief
>>> description of language. - Range of typical uses within Org
>>> Mode. - Link to this Org Mode file. * Requirements and Setup -
>>> Installation and configuration of language software - Emacs
>>> configuration * Org Mode Features for Language Source Code
>>> Blocks ** Org Mode Configuration - org-babel-do-load-languages
>>> ** Header Arguments - Language-specific default values -
>>> Language-specific header arguments ** Sessions - Support or
>>> not - Typical use for sessions ** Result Types - Which result
>>> types are supported? ** Other - Differences from other
>>> supported languages * Examples of Use - Hello World! - Common
>>> uses - Links to tutorials and other resources
>>>
>>>
>>> Eric Schulte <eric.schulte@gmx.com> writes:
>>>
>>>> Hi Tom,
>>>>
>>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>>
>>>>> Hi Eric,
>>>>>
>>>>> Yes, this is overdue. I think your plan is a good one.
>>>>>
>>>>> Perhaps a few of the individual use cases could be moved to
>>>>> FIXME, instead? I'm thinking here of Feiming Chen's R
>>>>> setup and some of my contributions when I was experimenting
>>>>> writing LaTeX inside source code blocks. The authors could
>>>>> resurrect these as they see fit.
>>>>>
>>>>
>>>> I don't know what FIXME is, but if there is a way to keep the
>>>> page in the worg git repository but remove it from the
>>>> exported HTML then that sounds ideal.
>>>>
>>>>>
>>>>> Hopefully, others will contribute use examples. My sense
>>>>> from reading the list is there are many interesting ones.
>>>>>
>>>>> I'd like it if Org mode users designed a template for the
>>>>> language specific pages. Currently, these seem to me a
>>>>> mixed bag and it would be good to regularize them.
>>>>
>>>> The below is a modified version of a template which can be
>>>> found in a couple of the existing language tutorials, I think
>>>> it serves as a good starting point.
>>>>
>>>> - Install and Setup - Instillation and configuration of
>>>> software (e.g., the language itself) - Configuration of Emacs
>>>> (e.g., activate language, set command path) - Examples -
>>>> Common ways to use the language in an Org-mode document -
>>>> Special cases - are there any language-specific header
>>>> arguments - does the language support session evaluation -
>>>> does the language support all result types - is the language
>>>> different from most babel languages (e.g., C is compiled
>>>> before execution, ditaa returns files, etc...)
>>>>
>>>>> It would also be nice to have one for each of the supported
>>>>> languages. There are 11 language specific pages now, which
>>>>> leaves quite a few languages under-documented.
>>>>
>>>> (length org-babel-load-languages) ;; => 27
>>>>
>>>> ls org-contrib/babel/languages/ob-doc-*|wc -l # => 11
>>>>
>>>> It looks like we have at least 16 more to go before we hit
>>>> full language coverage. Perhaps we should use the empty
>>>> cells in the "documentation" column in the languages table at
>>>> [1] as a sign up space for volunteers who would be willing to
>>>> write a brief tutorial demonstrating usage of Org-mode with
>>>> their favorite language.
>>>>
>>>> Moving forward this is likely something we could request of
>>>> the contributors of new languages.
>>>>
>>>> Also, once the template above is finalized it should be
>>>> posted on worg and linked to through the languages page.
>>>>
>>>>>
>>>>> I'll be happy to work on this as I can.
>>>>>
>>>>
>>>> Great, I don't anticipate having time to put towards this,
>>>> although I'll be happy to help troubleshoot where I can.
>>>>
>>>> Cheers,
>>>>
>>>>>
>>>>> All the best, Tom
>>>>>
>>>>>
>>>>> Eric Schulte <eric.schulte@gmx.com> writes:
>>>>>
>>>>>> Thanks for raising this point. The bulk of the content
>>>>>> in the Babel portion of worg is fairly old, predating the
>>>>>> syntax standardization efforts this fall. I've just
>>>>>> pushed some minor updates to the main babel pages, but
>>>>>> updating the language-specific tutorials and the
>>>>>> individual use cases will be a much larger effort.
>>>>>>
>>>>>> I'm not sure how to proceed. One option would be to go
>>>>>> through and add a [uses deprecated syntax] tag to the top
>>>>>> of each such page, which could be removed after the page
>>>>>> has been checked and possibly updated to ensure
>>>>>> consistency with the latest syntax.
>>>>>>
>>>>>> Given that the Babel syntax will not be changing
>>>>>> significantly moving forward now would be a good time to
>>>>>> do such a review. Ideally this could be completed before
>>>>>> the release of Emacs 24 in a couple of months.
>>>>>>
>>>>>> Any other ideas for update/reorganization or volunteers?
>>>>>>
>>>>>> Cheers,
>>>>>>
>>>>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>>>>
>>>>>>> Hi Riccardo,
>>>>>>>
>>>>>>> Thanks for the URL. Org mode has evolved since this
>>>>>>> article was written. It should probably be revised or
>>>>>>> taken off Worg. I've copied Eric Schulte, who is
>>>>>>> better able than me to determine the correct course of
>>>>>>> action here.
>>>>>>>
>>>>>>> In the meantime, an up-to-date description of how Org
>>>>>>> mode can be used to write literate programs has
>>>>>>> appeared in the Journal of Statistical Software. You
>>>>>>> can find it here: http://www.jstatsoft.org/v46/i03
>>>>>>>
>>>>>>> Perhaps you could use the examples in the JSS article
>>>>>>> to get started? If these don't work for you, or if they
>>>>>>> raise questions that are difficult to answer, please do
>>>>>>> come back to the list with your queries.
>>>>>>>
>>>>>>> All the best, Tom
>>>>>>>
>>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>>
>>>>>>>> Hi, this is the URL:
>>>>>>>>
>>>>>>>> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>>>>>>>>
>>>>>>>>
>>>>>>>>
Best
>>>>>>>> R
>>>>>>>>
>>>>>>>> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>>>>>>>>
>>>>>>>>> Hi Riccardo,
>>>>>>>>>
>>>>>>>>> This code appears to be outdated. I don't recall
>>>>>>>>> this code on the org site. Could you send a URL?
>>>>>>>>>
>>>>>>>>> All the best, Tom
>>>>>>>>>
>>>>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>>>>
>>>>>>>>>> Hi, I'm trying to generate some figure with R,
>>>>>>>>>> into an org session.
>>>>>>>>> Firstly
>>>>>>>>>> I use the code in the org site. The problem is
>>>>>>>>>> that the code do not generate any figure.
>>>>>>>>>>
>>>>>>>>>> This is the code:
>>>>>>>>>>
>>>>>>>>>> #+TITLE:Test #+AUTHOR: Your Name #+EMAIL:
>>>>>>>>>> your-email@server.com #+BABEL: :session *R*
>>>>>>>>>> :cache yes :results output graphics :exports both
>>>>>>>>>> :tangle yes
>>>>>>>>>>
>>>>>>>>>> * Example of Org-Babel for R Literate
>>>>>>>>>> Programming ** R text output A simple summary.
>>>>>>>>>> #+begin_src R x <- rnorm(10) summary(x)
>>>>>>>>>> #+end_src
>>>>>>>>>>
>>>>>>>>>> ** R graphics output Note we use the object =x=
>>>>>>>>>> generated in previous code block, thanks to the
>>>>>>>>>> header option =:session *R*=. The output
>>>>>>>>>> graphics file is =a.png=.
>>>>>>>>>>
>>>>>>>>>> #+begin_src R :file a.png y <- rnorm(10) plot(x,
>>>>>>>>>> y) #+end_src
>>>>>>>>>>
>>>>>>>>>> Same plot with larger dimension:
>>>>>>>>>>
>>>>>>>>>> #+begin_src R :file b.png :width 800 :height
>>>>>>>>>> 800 plot(x, y) #+end_src
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Where do I wrong?
>>>>>>>>>>
>>>>>>>>>> Best Riccardo Hi, I'm trying to generate some
>>>>>>>>>> figure with R, into an org session.
>>>>>>>>> Firstly I use the code in the org site. The problem
>>>>>>>>> is that the code do not generate any figure. This
>>>>>>>>> is the code:
>>>>>>>>>> #+TITLE:Test #+AUTHOR: Your Name #+EMAIL:
>>>>>>>>>> mailto:your-email@server.com #+BABEL: :session
>>>>>>>>>> *R* :cache yes :results output graphics :exports
>>>>>>>>>> both
>>>>>>>>> :tangle yes
>>>>>>>>>>
>>>>>>>>>> * Example of Org-Babel for R Literate
>>>>>>>>>> Programming ** R text output A simple summary.
>>>>>>>>>> #+begin_src R x <- rnorm(10) summary(x)
>>>>>>>>>> #+end_src
>>>>>>>>>>
>>>>>>>>>> ** R graphics output Note we use the object =x=
>>>>>>>>>> generated in previous code block, thanks to the
>>>>>>>>>> header option =:session *R*=. The output
>>>>>>>>>> graphics file is =a.png=.
>>>>>>>>>>
>>>>>>>>>> #+begin_src R :file a.png y <- rnorm(10) plot(x,
>>>>>>>>>> y) #+end_src
>>>>>>>>>>
>>>>>>>>>> Same plot with larger dimension:
>>>>>>>>>>
>>>>>>>>>> #+begin_src R :file b.png :width 800 :height
>>>>>>>>>> 800 plot(x, y) #+end_src Where do I
>>>>>>>>>> wrong?BestRiccardo
>>>>>>>>>
>>>>>>>>> -- Thomas S. Dye http://www.tsdye.com
>>>>>>>>>
>>>>>>>> Hi, this is the
>>>>>>>> URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
>>>>>>>>
>>>>>>>>
2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi
Riccardo,
>>>>>>>>
>>>>>>>>
>>>>>>>> This code appears to be outdated. I don't recall
>>>>>>>> this code on the org site. Could you send a URL?
>>>>>>>>
>>>>>>>> All the best, Tom
>>>>>>>>
>>>>>>>> Riccardo Romoli <mailto:ric.romoli@gmail.com>
>>>>>>>> writes:
>>>>>>>>
>>>>>>>>> Hi, I'm trying to generate some figure with R,
>>>>>>>>> into an org session. Firstly I use the code in the
>>>>>>>>> org site. The problem is that the code do not
>>>>>>>>> generate any figure.
>>>>>>>>>
>>>>>>>>> This is the code:
>>>>>>>>>
>>>>>>>>> #+TITLE:Test #+AUTHOR: Your Name #+EMAIL:
>>>>>>>>> mailto:your-email@server.com #+BABEL: :session *R*
>>>>>>>>> :cache yes :results output graphics :exports both
>>>>>>>>> :tangle yes
>>>>>>>>>
>>>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>>>> ** R text output A simple summary. #+begin_src R x
>>>>>>>>> <- rnorm(10) summary(x) #+end_src
>>>>>>>>>
>>>>>>>>> ** R graphics output Note we use the object =x=
>>>>>>>>> generated in previous code block, thanks to the
>>>>>>>>> header option =:session *R*=. The output graphics
>>>>>>>>> file is =a.png=.
>>>>>>>>>
>>>>>>>>> #+begin_src R :file a.png y <- rnorm(10) plot(x,
>>>>>>>>> y) #+end_src
>>>>>>>>>
>>>>>>>>> Same plot with larger dimension:
>>>>>>>>>
>>>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>>>> plot(x, y) #+end_src
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Where do I wrong?
>>>>>>>>>
>>>>>>>>> Best Riccardo Hi, I'm trying to generate some
>>>>>>>>> figure with R, into an org session. Firstly I use
>>>>>>>>> the code in the org site. The problem is that the
>>>>>>>>> code do not generate any figure. This is the code:
>>>>>>>>> #+TITLE:Test #+AUTHOR: Your Name #+EMAIL:
>>>>>>>>> mailto:mailto:your-email@server.com #+BABEL:
>>>>>>>>> :session *R* :cache yes :results output graphics
>>>>>>>>> :exports both :tangle yes
>>>>>>>>>
>>>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>>>> ** R text output A simple summary. #+begin_src R x
>>>>>>>>> <- rnorm(10) summary(x) #+end_src
>>>>>>>>>
>>>>>>>>> ** R graphics output Note we use the object =x=
>>>>>>>>> generated in previous code block, thanks to the
>>>>>>>>> header option =:session *R*=. The output graphics
>>>>>>>>> file is =a.png=.
>>>>>>>>>
>>>>>>>>> #+begin_src R :file a.png y <- rnorm(10) plot(x,
>>>>>>>>> y) #+end_src
>>>>>>>>>
>>>>>>>>> Same plot with larger dimension:
>>>>>>>>>
>>>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>>>> plot(x, y) #+end_src Where do I wrong?BestRiccardo
>>>>>>>>
>>>>>>>> <span class="HOEnZb">-- Thomas S. Dye
>>>>>>>> http://www.tsdye.com </span>
>>>>
>>>>
>>>> Footnotes: [1]
>>>> http://orgmode.org/worg/org-contrib/babel/languages.html
>>
>>
>
>
> Footnotes: [1]
> http://orgmode.org/worg/org-contrib/babel/languages.html
>
- --
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation
Biology, UCT), Dipl. Phys. (Germany)
Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa
Tel : +33 - (0)9 53 10 27 44
Cell: +33 - (0)6 85 62 59 98
Fax : +33 - (0)9 58 10 27 44
Fax (D): +49 - (0)3 21 21 25 22 44
email: Rainer@krugs.de
Skype: RMkrug
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAk8yijYACgkQoYgNqgF2egrYOgCePUalLt/aey4qysCIwfXsJC3i
Z7oAni4fmMDJbQpnEiHcu7KwQ3/eo14I
=hls7
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Updating the Babel section of Worg
2012-02-08 14:44 ` Rainer M Krug
@ 2012-02-08 15:27 ` Eric Schulte
0 siblings, 0 replies; 17+ messages in thread
From: Eric Schulte @ 2012-02-08 15:27 UTC (permalink / raw
To: R.M.Krug; +Cc: Martyn Jago, emacs-orgmode
Rainer M Krug <r.m.krug@gmail.com> writes:
> On 08/02/12 15:21, Eric Schulte wrote:
>> Martyn Jago <martyn.jago@btinternet.com> writes:
>>
>>> Hi Thomas and Eric
>>>
>>> Love it. I will try to help!
>>>
>>> Worg is a great resource that is getting better and better.
>>>
>>> The template looks good (Babel wise) and should be up there as a
>>> check-sheet, although maybe not as a requirement.
>>>
>>
>> I agree, I've just linked to it from the languages page [1] with
>> the following statement. Please feel free to edit this directly on
>> worg if it sounds too strong.
>
> Nice - I will take a look at it.
>
> Just to make it easier for non-regular worg contributors: I would
> suggest to give an email where one can send the completed template to
> to be submitted to worg.
>
I will be happy to apply any language documentation sent to this list.
Best,
--
Eric Schulte
http://cs.unm.edu/~eschulte/
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Updating the Babel section of Worg
2012-02-08 0:01 ` Thomas S. Dye
2012-02-08 1:04 ` Martyn Jago
2012-02-08 14:14 ` Eric Schulte
@ 2012-02-08 15:41 ` John Hendy
2 siblings, 0 replies; 17+ messages in thread
From: John Hendy @ 2012-02-08 15:41 UTC (permalink / raw
To: Thomas S. Dye; +Cc: emacs-orgmode, Eric Schulte, Riccardo Romoli
On Tue, Feb 7, 2012 at 6:01 PM, Thomas S. Dye <tsd@tsdye.com> wrote:
> Hi Eric,
>
> I've attached a first draft of a template for review and revision. It
> is heavily influenced by John Hendy's terrific gnuplot page. I
> believe it incorporates the points in your outline. Feel free to
> edit as appropriate.
>
Thanks for the kind words. I give the credit to Nick Dokos and Eric
Schulte for encouraging me to post my solution on Worg once I found
it.
-- http://www.mail-archive.com/emacs-orgmode@gnu.org/msg28995.html
I hate to say it, but without that nudge I might have "dined and
dashed" -- gotten help from the list, solved the issue, and then
returned to my cave :) Glad it proved useful!
Best regards,
John
> All the best,
> Tom
>
>
>
>
> Eric Schulte <eric.schulte@gmx.com> writes:
>
>> Hi Tom,
>>
>> tsd@tsdye.com (Thomas S. Dye) writes:
>>
>>> Hi Eric,
>>>
>>> Yes, this is overdue. I think your plan is a good one.
>>>
>>> Perhaps a few of the individual use cases could be moved to FIXME,
>>> instead? I'm thinking here of Feiming Chen's R setup and some of my
>>> contributions when I was experimenting writing LaTeX inside source
>>> code blocks. The authors could resurrect these as they see fit.
>>>
>>
>> I don't know what FIXME is, but if there is a way to keep the page in
>> the worg git repository but remove it from the exported HTML then that
>> sounds ideal.
>>
>>>
>>> Hopefully, others will contribute use examples. My sense from reading
>>> the list is there are many interesting ones.
>>>
>>> I'd like it if Org mode users designed a template for the language
>>> specific pages. Currently, these seem to me a mixed bag and it would be
>>> good to regularize them.
>>
>> The below is a modified version of a template which can be found in a
>> couple of the existing language tutorials, I think it serves as a good
>> starting point.
>>
>> - Install and Setup
>> - Instillation and configuration of software (e.g., the language itself)
>> - Configuration of Emacs (e.g., activate language, set command path)
>> - Examples
>> - Common ways to use the language in an Org-mode document
>> - Special cases
>> - are there any language-specific header arguments
>> - does the language support session evaluation
>> - does the language support all result types
>> - is the language different from most babel languages
>> (e.g., C is compiled before execution, ditaa returns files, etc...)
>>
>>> It would also be nice to have one for each of the supported languages.
>>> There are 11 language specific pages now, which leaves quite a few
>>> languages under-documented.
>>
>> (length org-babel-load-languages) ;; => 27
>>
>> ls org-contrib/babel/languages/ob-doc-*|wc -l # => 11
>>
>> It looks like we have at least 16 more to go before we hit full language
>> coverage. Perhaps we should use the empty cells in the "documentation"
>> column in the languages table at [1] as a sign up space for volunteers
>> who would be willing to write a brief tutorial demonstrating usage of
>> Org-mode with their favorite language.
>>
>> Moving forward this is likely something we could request of the
>> contributors of new languages.
>>
>> Also, once the template above is finalized it should be posted on worg
>> and linked to through the languages page.
>>
>>>
>>> I'll be happy to work on this as I can.
>>>
>>
>> Great, I don't anticipate having time to put towards this, although I'll
>> be happy to help troubleshoot where I can.
>>
>> Cheers,
>>
>>>
>>> All the best,
>>> Tom
>>>
>>>
>>> Eric Schulte <eric.schulte@gmx.com> writes:
>>>
>>>> Thanks for raising this point. The bulk of the content in the Babel
>>>> portion of worg is fairly old, predating the syntax standardization
>>>> efforts this fall. I've just pushed some minor updates to the main
>>>> babel pages, but updating the language-specific tutorials and the
>>>> individual use cases will be a much larger effort.
>>>>
>>>> I'm not sure how to proceed. One option would be to go through and add
>>>> a [uses deprecated syntax] tag to the top of each such page, which could
>>>> be removed after the page has been checked and possibly updated to
>>>> ensure consistency with the latest syntax.
>>>>
>>>> Given that the Babel syntax will not be changing significantly moving
>>>> forward now would be a good time to do such a review. Ideally this
>>>> could be completed before the release of Emacs 24 in a couple of months.
>>>>
>>>> Any other ideas for update/reorganization or volunteers?
>>>>
>>>> Cheers,
>>>>
>>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>>
>>>>> Hi Riccardo,
>>>>>
>>>>> Thanks for the URL. Org mode has evolved since this article was
>>>>> written. It should probably be revised or taken off Worg. I've copied
>>>>> Eric Schulte, who is better able than me to determine the correct course
>>>>> of action here.
>>>>>
>>>>> In the meantime, an up-to-date description of how Org mode can be used
>>>>> to write literate programs has appeared in the Journal of Statistical
>>>>> Software. You can find it here: http://www.jstatsoft.org/v46/i03
>>>>>
>>>>> Perhaps you could use the examples in the JSS article to get started?
>>>>> If these don't work for you, or if they raise questions that are difficult
>>>>> to answer, please do come back to the list with your queries.
>>>>>
>>>>> All the best,
>>>>> Tom
>>>>>
>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>
>>>>>> Hi, this is the URL:
>>>>>>
>>>>>> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>>>>>>
>>>>>> Best
>>>>>> R
>>>>>>
>>>>>> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>>>>>>
>>>>>>> Hi Riccardo,
>>>>>>>
>>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>>> site. Could you send a URL?
>>>>>>>
>>>>>>> All the best,
>>>>>>> Tom
>>>>>>>
>>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>>
>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>> Firstly
>>>>>>> > I use the code in the org site. The problem is that the code do not
>>>>>>> > generate any figure.
>>>>>>> >
>>>>>>> > This is the code:
>>>>>>> >
>>>>>>> > #+TITLE:Test
>>>>>>> > #+AUTHOR: Your Name
>>>>>>> > #+EMAIL: your-email@server.com
>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>> > both :tangle yes
>>>>>>> >
>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>> > ** R text output
>>>>>>> > A simple summary.
>>>>>>> > #+begin_src R
>>>>>>> > x <- rnorm(10)
>>>>>>> > summary(x)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > ** R graphics output
>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>> > =a.png=.
>>>>>>> >
>>>>>>> > #+begin_src R :file a.png
>>>>>>> > y <- rnorm(10)
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > Same plot with larger dimension:
>>>>>>> >
>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> >
>>>>>>> > Where do I wrong?
>>>>>>> >
>>>>>>> > Best
>>>>>>> > Riccardo
>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>> Firstly I use the code in the org site. The problem is that the code do not
>>>>>>> generate any figure. This is the code:
>>>>>>> > #+TITLE:Test
>>>>>>> > #+AUTHOR: Your Name
>>>>>>> > #+EMAIL: mailto:your-email@server.com
>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
>>>>>>> :tangle yes
>>>>>>> >
>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>> > ** R text output
>>>>>>> > A simple summary.
>>>>>>> > #+begin_src R
>>>>>>> > x <- rnorm(10)
>>>>>>> > summary(x)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > ** R graphics output
>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>> > =a.png=.
>>>>>>> >
>>>>>>> > #+begin_src R :file a.png
>>>>>>> > y <- rnorm(10)
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> >
>>>>>>> > Same plot with larger dimension:
>>>>>>> >
>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>> > plot(x, y)
>>>>>>> > #+end_src
>>>>>>> > Where do I wrong?BestRiccardo
>>>>>>>
>>>>>>> --
>>>>>>> Thomas S. Dye
>>>>>>> http://www.tsdye.com
>>>>>>>
>>>>>> Hi, this is the URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
>>>>>> 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi Riccardo,
>>>>>>
>>>>>>
>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>> site. Could you send a URL?
>>>>>>
>>>>>> All the best,
>>>>>> Tom
>>>>>>
>>>>>> Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
>>>>>>
>>>>>>> Hi, I'm trying to generate some figure with R, into an org session. Firstly
>>>>>>> I use the code in the org site. The problem is that the code do not
>>>>>>> generate any figure.
>>>>>>>
>>>>>>> This is the code:
>>>>>>>
>>>>>>> #+TITLE:Test
>>>>>>> #+AUTHOR: Your Name
>>>>>>> #+EMAIL: mailto:your-email@server.com
>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>> both :tangle yes
>>>>>>>
>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>> ** R text output
>>>>>>> A simple summary.
>>>>>>> #+begin_src R
>>>>>>> x <- rnorm(10)
>>>>>>> summary(x)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> ** R graphics output
>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>> =a.png=.
>>>>>>>
>>>>>>> #+begin_src R :file a.png
>>>>>>> y <- rnorm(10)
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> Same plot with larger dimension:
>>>>>>>
>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>>
>>>>>>>
>>>>>>> Where do I wrong?
>>>>>>>
>>>>>>> Best
>>>>>>> Riccardo
>>>>>>> Hi, I'm trying to generate some figure with R, into an org
>>>>>>> session. Firstly I use the code in the org site. The problem is
>>>>>>> that the code do not generate any figure. This is the code:
>>>>>>> #+TITLE:Test
>>>>>>> #+AUTHOR: Your Name
>>>>>>> #+EMAIL: mailto:mailto:your-email@server.com
>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>>>>>>>
>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>> ** R text output
>>>>>>> A simple summary.
>>>>>>> #+begin_src R
>>>>>>> x <- rnorm(10)
>>>>>>> summary(x)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> ** R graphics output
>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>> =a.png=.
>>>>>>>
>>>>>>> #+begin_src R :file a.png
>>>>>>> y <- rnorm(10)
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>>
>>>>>>> Same plot with larger dimension:
>>>>>>>
>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>> plot(x, y)
>>>>>>> #+end_src
>>>>>>> Where do I wrong?BestRiccardo
>>>>>>
>>>>>> <span class="HOEnZb">--
>>>>>> Thomas S. Dye
>>>>>> http://www.tsdye.com
>>>>>> </span>
>>
>>
>> Footnotes:
>> [1] http://orgmode.org/worg/org-contrib/babel/languages.html
>
> --
> Thomas S. Dye
> http://www.tsdye.com
>
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Updating the Babel section of Worg
2012-02-08 14:14 ` Eric Schulte
@ 2012-02-09 17:20 ` Thomas S. Dye
2012-02-18 21:53 ` Eric Schulte
0 siblings, 1 reply; 17+ messages in thread
From: Thomas S. Dye @ 2012-02-09 17:20 UTC (permalink / raw
To: Eric Schulte; +Cc: emacs-orgmode
Hi Eric,
I pushed a draft of the revised LaTeX language section to Worg
(http://orgmode.org/worg/org-contrib/babel/languages/ob-doc-LaTeX.html).
Please take a look and edit as necessary. Too often I understand
these things partially!
If Andreas Leha is reading this it would be good to take a look at my
description of the ImageMagick facility. I tried to stick closely to
the sources, but might have strayed.
All the best,
Tom
Eric Schulte <eric.schulte@gmx.com> writes:
> tsd@tsdye.com (Thomas S. Dye) writes:
>
>> Hi Eric,
>>
>> I've attached a first draft of a template for review and revision. It
>> is heavily influenced by John Hendy's terrific gnuplot page. I
>> believe it incorporates the points in your outline. Feel free to
>> edit as appropriate.
>>
>
> Looks great to me. I made a small change, and I've just pushed it up to
> worg and linked to it from the languages page. We can continue to
> improve this template as needed on worg although I think it is already
> in very good shape and ready for use.
>
> Thanks,
>
>>
>> All the best,
>> Tom
>>
>>
>>
>>
>> Eric Schulte <eric.schulte@gmx.com> writes:
>>
>>> Hi Tom,
>>>
>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>
>>>> Hi Eric,
>>>>
>>>> Yes, this is overdue. I think your plan is a good one.
>>>>
>>>> Perhaps a few of the individual use cases could be moved to FIXME,
>>>> instead? I'm thinking here of Feiming Chen's R setup and some of my
>>>> contributions when I was experimenting writing LaTeX inside source
>>>> code blocks. The authors could resurrect these as they see fit.
>>>>
>>>
>>> I don't know what FIXME is, but if there is a way to keep the page in
>>> the worg git repository but remove it from the exported HTML then that
>>> sounds ideal.
>>>
>>>>
>>>> Hopefully, others will contribute use examples. My sense from reading
>>>> the list is there are many interesting ones.
>>>>
>>>> I'd like it if Org mode users designed a template for the language
>>>> specific pages. Currently, these seem to me a mixed bag and it would be
>>>> good to regularize them.
>>>
>>> The below is a modified version of a template which can be found in a
>>> couple of the existing language tutorials, I think it serves as a good
>>> starting point.
>>>
>>> - Install and Setup
>>> - Instillation and configuration of software (e.g., the language itself)
>>> - Configuration of Emacs (e.g., activate language, set command path)
>>> - Examples
>>> - Common ways to use the language in an Org-mode document
>>> - Special cases
>>> - are there any language-specific header arguments
>>> - does the language support session evaluation
>>> - does the language support all result types
>>> - is the language different from most babel languages
>>> (e.g., C is compiled before execution, ditaa returns files, etc...)
>>>
>>>> It would also be nice to have one for each of the supported languages.
>>>> There are 11 language specific pages now, which leaves quite a few
>>>> languages under-documented.
>>>
>>> (length org-babel-load-languages) ;; => 27
>>>
>>> ls org-contrib/babel/languages/ob-doc-*|wc -l # => 11
>>>
>>> It looks like we have at least 16 more to go before we hit full language
>>> coverage. Perhaps we should use the empty cells in the "documentation"
>>> column in the languages table at [1] as a sign up space for volunteers
>>> who would be willing to write a brief tutorial demonstrating usage of
>>> Org-mode with their favorite language.
>>>
>>> Moving forward this is likely something we could request of the
>>> contributors of new languages.
>>>
>>> Also, once the template above is finalized it should be posted on worg
>>> and linked to through the languages page.
>>>
>>>>
>>>> I'll be happy to work on this as I can.
>>>>
>>>
>>> Great, I don't anticipate having time to put towards this, although I'll
>>> be happy to help troubleshoot where I can.
>>>
>>> Cheers,
>>>
>>>>
>>>> All the best,
>>>> Tom
>>>>
>>>>
>>>> Eric Schulte <eric.schulte@gmx.com> writes:
>>>>
>>>>> Thanks for raising this point. The bulk of the content in the Babel
>>>>> portion of worg is fairly old, predating the syntax standardization
>>>>> efforts this fall. I've just pushed some minor updates to the main
>>>>> babel pages, but updating the language-specific tutorials and the
>>>>> individual use cases will be a much larger effort.
>>>>>
>>>>> I'm not sure how to proceed. One option would be to go through and add
>>>>> a [uses deprecated syntax] tag to the top of each such page, which could
>>>>> be removed after the page has been checked and possibly updated to
>>>>> ensure consistency with the latest syntax.
>>>>>
>>>>> Given that the Babel syntax will not be changing significantly moving
>>>>> forward now would be a good time to do such a review. Ideally this
>>>>> could be completed before the release of Emacs 24 in a couple of months.
>>>>>
>>>>> Any other ideas for update/reorganization or volunteers?
>>>>>
>>>>> Cheers,
>>>>>
>>>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>>>
>>>>>> Hi Riccardo,
>>>>>>
>>>>>> Thanks for the URL. Org mode has evolved since this article was
>>>>>> written. It should probably be revised or taken off Worg. I've copied
>>>>>> Eric Schulte, who is better able than me to determine the correct course
>>>>>> of action here.
>>>>>>
>>>>>> In the meantime, an up-to-date description of how Org mode can be used
>>>>>> to write literate programs has appeared in the Journal of Statistical
>>>>>> Software. You can find it here: http://www.jstatsoft.org/v46/i03
>>>>>>
>>>>>> Perhaps you could use the examples in the JSS article to get started?
>>>>>> If these don't work for you, or if they raise questions that are difficult
>>>>>> to answer, please do come back to the list with your queries.
>>>>>>
>>>>>> All the best,
>>>>>> Tom
>>>>>>
>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>
>>>>>>> Hi, this is the URL:
>>>>>>>
>>>>>>> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>>>>>>>
>>>>>>> Best
>>>>>>> R
>>>>>>>
>>>>>>> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>>>>>>>
>>>>>>>> Hi Riccardo,
>>>>>>>>
>>>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>>>> site. Could you send a URL?
>>>>>>>>
>>>>>>>> All the best,
>>>>>>>> Tom
>>>>>>>>
>>>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>>>
>>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>>> Firstly
>>>>>>>> > I use the code in the org site. The problem is that the code do not
>>>>>>>> > generate any figure.
>>>>>>>> >
>>>>>>>> > This is the code:
>>>>>>>> >
>>>>>>>> > #+TITLE:Test
>>>>>>>> > #+AUTHOR: Your Name
>>>>>>>> > #+EMAIL: your-email@server.com
>>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>>> > both :tangle yes
>>>>>>>> >
>>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>>> > ** R text output
>>>>>>>> > A simple summary.
>>>>>>>> > #+begin_src R
>>>>>>>> > x <- rnorm(10)
>>>>>>>> > summary(x)
>>>>>>>> > #+end_src
>>>>>>>> >
>>>>>>>> > ** R graphics output
>>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>>> > =a.png=.
>>>>>>>> >
>>>>>>>> > #+begin_src R :file a.png
>>>>>>>> > y <- rnorm(10)
>>>>>>>> > plot(x, y)
>>>>>>>> > #+end_src
>>>>>>>> >
>>>>>>>> > Same plot with larger dimension:
>>>>>>>> >
>>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>>> > plot(x, y)
>>>>>>>> > #+end_src
>>>>>>>> >
>>>>>>>> >
>>>>>>>> > Where do I wrong?
>>>>>>>> >
>>>>>>>> > Best
>>>>>>>> > Riccardo
>>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>>> Firstly I use the code in the org site. The problem is that the code do not
>>>>>>>> generate any figure. This is the code:
>>>>>>>> > #+TITLE:Test
>>>>>>>> > #+AUTHOR: Your Name
>>>>>>>> > #+EMAIL: mailto:your-email@server.com
>>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
>>>>>>>> :tangle yes
>>>>>>>> >
>>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>>> > ** R text output
>>>>>>>> > A simple summary.
>>>>>>>> > #+begin_src R
>>>>>>>> > x <- rnorm(10)
>>>>>>>> > summary(x)
>>>>>>>> > #+end_src
>>>>>>>> >
>>>>>>>> > ** R graphics output
>>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>>> > =a.png=.
>>>>>>>> >
>>>>>>>> > #+begin_src R :file a.png
>>>>>>>> > y <- rnorm(10)
>>>>>>>> > plot(x, y)
>>>>>>>> > #+end_src
>>>>>>>> >
>>>>>>>> > Same plot with larger dimension:
>>>>>>>> >
>>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>>> > plot(x, y)
>>>>>>>> > #+end_src
>>>>>>>> > Where do I wrong?BestRiccardo
>>>>>>>>
>>>>>>>> --
>>>>>>>> Thomas S. Dye
>>>>>>>> http://www.tsdye.com
>>>>>>>>
>>>>>>> Hi, this is the URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
>>>>>>> 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi Riccardo,
>>>>>>>
>>>>>>>
>>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>>> site. Could you send a URL?
>>>>>>>
>>>>>>> All the best,
>>>>>>> Tom
>>>>>>>
>>>>>>> Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
>>>>>>>
>>>>>>>> Hi, I'm trying to generate some figure with R, into an org session. Firstly
>>>>>>>> I use the code in the org site. The problem is that the code do not
>>>>>>>> generate any figure.
>>>>>>>>
>>>>>>>> This is the code:
>>>>>>>>
>>>>>>>> #+TITLE:Test
>>>>>>>> #+AUTHOR: Your Name
>>>>>>>> #+EMAIL: mailto:your-email@server.com
>>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>>> both :tangle yes
>>>>>>>>
>>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>>> ** R text output
>>>>>>>> A simple summary.
>>>>>>>> #+begin_src R
>>>>>>>> x <- rnorm(10)
>>>>>>>> summary(x)
>>>>>>>> #+end_src
>>>>>>>>
>>>>>>>> ** R graphics output
>>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>>> =a.png=.
>>>>>>>>
>>>>>>>> #+begin_src R :file a.png
>>>>>>>> y <- rnorm(10)
>>>>>>>> plot(x, y)
>>>>>>>> #+end_src
>>>>>>>>
>>>>>>>> Same plot with larger dimension:
>>>>>>>>
>>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>>> plot(x, y)
>>>>>>>> #+end_src
>>>>>>>>
>>>>>>>>
>>>>>>>> Where do I wrong?
>>>>>>>>
>>>>>>>> Best
>>>>>>>> Riccardo
>>>>>>>> Hi, I'm trying to generate some figure with R, into an org
>>>>>>>> session. Firstly I use the code in the org site. The problem is
>>>>>>>> that the code do not generate any figure. This is the code:
>>>>>>>> #+TITLE:Test
>>>>>>>> #+AUTHOR: Your Name
>>>>>>>> #+EMAIL: mailto:mailto:your-email@server.com
>>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>>>>>>>>
>>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>>> ** R text output
>>>>>>>> A simple summary.
>>>>>>>> #+begin_src R
>>>>>>>> x <- rnorm(10)
>>>>>>>> summary(x)
>>>>>>>> #+end_src
>>>>>>>>
>>>>>>>> ** R graphics output
>>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>>> =a.png=.
>>>>>>>>
>>>>>>>> #+begin_src R :file a.png
>>>>>>>> y <- rnorm(10)
>>>>>>>> plot(x, y)
>>>>>>>> #+end_src
>>>>>>>>
>>>>>>>> Same plot with larger dimension:
>>>>>>>>
>>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>>> plot(x, y)
>>>>>>>> #+end_src
>>>>>>>> Where do I wrong?BestRiccardo
>>>>>>>
>>>>>>> <span class="HOEnZb">--
>>>>>>> Thomas S. Dye
>>>>>>> http://www.tsdye.com
>>>>>>> </span>
>>>
>>>
>>> Footnotes:
>>> [1] http://orgmode.org/worg/org-contrib/babel/languages.html
--
Thomas S. Dye
http://www.tsdye.com
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: Updating the Babel section of Worg
2012-02-09 17:20 ` Thomas S. Dye
@ 2012-02-18 21:53 ` Eric Schulte
0 siblings, 0 replies; 17+ messages in thread
From: Eric Schulte @ 2012-02-18 21:53 UTC (permalink / raw
To: Thomas S. Dye; +Cc: emacs-orgmode
tsd@tsdye.com (Thomas S. Dye) writes:
> Hi Eric,
>
> I pushed a draft of the revised LaTeX language section to Worg
> (http://orgmode.org/worg/org-contrib/babel/languages/ob-doc-LaTeX.html).
>
> Please take a look and edit as necessary. Too often I understand
> these things partially!
>
Everything looks great to me. Thanks for the contribution!
>
> If Andreas Leha is reading this it would be good to take a look at my
> description of the ImageMagick facility. I tried to stick closely to
> the sources, but might have strayed.
>
> All the best,
> Tom
>
> Eric Schulte <eric.schulte@gmx.com> writes:
>
>> tsd@tsdye.com (Thomas S. Dye) writes:
>>
>>> Hi Eric,
>>>
>>> I've attached a first draft of a template for review and revision. It
>>> is heavily influenced by John Hendy's terrific gnuplot page. I
>>> believe it incorporates the points in your outline. Feel free to
>>> edit as appropriate.
>>>
>>
>> Looks great to me. I made a small change, and I've just pushed it up to
>> worg and linked to it from the languages page. We can continue to
>> improve this template as needed on worg although I think it is already
>> in very good shape and ready for use.
>>
>> Thanks,
>>
>>>
>>> All the best,
>>> Tom
>>>
>>>
>>>
>>>
>>> Eric Schulte <eric.schulte@gmx.com> writes:
>>>
>>>> Hi Tom,
>>>>
>>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>>
>>>>> Hi Eric,
>>>>>
>>>>> Yes, this is overdue. I think your plan is a good one.
>>>>>
>>>>> Perhaps a few of the individual use cases could be moved to FIXME,
>>>>> instead? I'm thinking here of Feiming Chen's R setup and some of my
>>>>> contributions when I was experimenting writing LaTeX inside source
>>>>> code blocks. The authors could resurrect these as they see fit.
>>>>>
>>>>
>>>> I don't know what FIXME is, but if there is a way to keep the page in
>>>> the worg git repository but remove it from the exported HTML then that
>>>> sounds ideal.
>>>>
>>>>>
>>>>> Hopefully, others will contribute use examples. My sense from reading
>>>>> the list is there are many interesting ones.
>>>>>
>>>>> I'd like it if Org mode users designed a template for the language
>>>>> specific pages. Currently, these seem to me a mixed bag and it would be
>>>>> good to regularize them.
>>>>
>>>> The below is a modified version of a template which can be found in a
>>>> couple of the existing language tutorials, I think it serves as a good
>>>> starting point.
>>>>
>>>> - Install and Setup
>>>> - Instillation and configuration of software (e.g., the language itself)
>>>> - Configuration of Emacs (e.g., activate language, set command path)
>>>> - Examples
>>>> - Common ways to use the language in an Org-mode document
>>>> - Special cases
>>>> - are there any language-specific header arguments
>>>> - does the language support session evaluation
>>>> - does the language support all result types
>>>> - is the language different from most babel languages
>>>> (e.g., C is compiled before execution, ditaa returns files, etc...)
>>>>
>>>>> It would also be nice to have one for each of the supported languages.
>>>>> There are 11 language specific pages now, which leaves quite a few
>>>>> languages under-documented.
>>>>
>>>> (length org-babel-load-languages) ;; => 27
>>>>
>>>> ls org-contrib/babel/languages/ob-doc-*|wc -l # => 11
>>>>
>>>> It looks like we have at least 16 more to go before we hit full language
>>>> coverage. Perhaps we should use the empty cells in the "documentation"
>>>> column in the languages table at [1] as a sign up space for volunteers
>>>> who would be willing to write a brief tutorial demonstrating usage of
>>>> Org-mode with their favorite language.
>>>>
>>>> Moving forward this is likely something we could request of the
>>>> contributors of new languages.
>>>>
>>>> Also, once the template above is finalized it should be posted on worg
>>>> and linked to through the languages page.
>>>>
>>>>>
>>>>> I'll be happy to work on this as I can.
>>>>>
>>>>
>>>> Great, I don't anticipate having time to put towards this, although I'll
>>>> be happy to help troubleshoot where I can.
>>>>
>>>> Cheers,
>>>>
>>>>>
>>>>> All the best,
>>>>> Tom
>>>>>
>>>>>
>>>>> Eric Schulte <eric.schulte@gmx.com> writes:
>>>>>
>>>>>> Thanks for raising this point. The bulk of the content in the Babel
>>>>>> portion of worg is fairly old, predating the syntax standardization
>>>>>> efforts this fall. I've just pushed some minor updates to the main
>>>>>> babel pages, but updating the language-specific tutorials and the
>>>>>> individual use cases will be a much larger effort.
>>>>>>
>>>>>> I'm not sure how to proceed. One option would be to go through and add
>>>>>> a [uses deprecated syntax] tag to the top of each such page, which could
>>>>>> be removed after the page has been checked and possibly updated to
>>>>>> ensure consistency with the latest syntax.
>>>>>>
>>>>>> Given that the Babel syntax will not be changing significantly moving
>>>>>> forward now would be a good time to do such a review. Ideally this
>>>>>> could be completed before the release of Emacs 24 in a couple of months.
>>>>>>
>>>>>> Any other ideas for update/reorganization or volunteers?
>>>>>>
>>>>>> Cheers,
>>>>>>
>>>>>> tsd@tsdye.com (Thomas S. Dye) writes:
>>>>>>
>>>>>>> Hi Riccardo,
>>>>>>>
>>>>>>> Thanks for the URL. Org mode has evolved since this article was
>>>>>>> written. It should probably be revised or taken off Worg. I've copied
>>>>>>> Eric Schulte, who is better able than me to determine the correct course
>>>>>>> of action here.
>>>>>>>
>>>>>>> In the meantime, an up-to-date description of how Org mode can be used
>>>>>>> to write literate programs has appeared in the Journal of Statistical
>>>>>>> Software. You can find it here: http://www.jstatsoft.org/v46/i03
>>>>>>>
>>>>>>> Perhaps you could use the examples in the JSS article to get started?
>>>>>>> If these don't work for you, or if they raise questions that are difficult
>>>>>>> to answer, please do come back to the list with your queries.
>>>>>>>
>>>>>>> All the best,
>>>>>>> Tom
>>>>>>>
>>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>>
>>>>>>>> Hi, this is the URL:
>>>>>>>>
>>>>>>>> http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.html
>>>>>>>>
>>>>>>>> Best
>>>>>>>> R
>>>>>>>>
>>>>>>>> 2012/2/5 Thomas S. Dye <tsd@tsdye.com>
>>>>>>>>
>>>>>>>>> Hi Riccardo,
>>>>>>>>>
>>>>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>>>>> site. Could you send a URL?
>>>>>>>>>
>>>>>>>>> All the best,
>>>>>>>>> Tom
>>>>>>>>>
>>>>>>>>> Riccardo Romoli <ric.romoli@gmail.com> writes:
>>>>>>>>>
>>>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>>>> Firstly
>>>>>>>>> > I use the code in the org site. The problem is that the code do not
>>>>>>>>> > generate any figure.
>>>>>>>>> >
>>>>>>>>> > This is the code:
>>>>>>>>> >
>>>>>>>>> > #+TITLE:Test
>>>>>>>>> > #+AUTHOR: Your Name
>>>>>>>>> > #+EMAIL: your-email@server.com
>>>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>>>> > both :tangle yes
>>>>>>>>> >
>>>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>>>> > ** R text output
>>>>>>>>> > A simple summary.
>>>>>>>>> > #+begin_src R
>>>>>>>>> > x <- rnorm(10)
>>>>>>>>> > summary(x)
>>>>>>>>> > #+end_src
>>>>>>>>> >
>>>>>>>>> > ** R graphics output
>>>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>>>> > =a.png=.
>>>>>>>>> >
>>>>>>>>> > #+begin_src R :file a.png
>>>>>>>>> > y <- rnorm(10)
>>>>>>>>> > plot(x, y)
>>>>>>>>> > #+end_src
>>>>>>>>> >
>>>>>>>>> > Same plot with larger dimension:
>>>>>>>>> >
>>>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>>>> > plot(x, y)
>>>>>>>>> > #+end_src
>>>>>>>>> >
>>>>>>>>> >
>>>>>>>>> > Where do I wrong?
>>>>>>>>> >
>>>>>>>>> > Best
>>>>>>>>> > Riccardo
>>>>>>>>> > Hi, I'm trying to generate some figure with R, into an org session.
>>>>>>>>> Firstly I use the code in the org site. The problem is that the code do not
>>>>>>>>> generate any figure. This is the code:
>>>>>>>>> > #+TITLE:Test
>>>>>>>>> > #+AUTHOR: Your Name
>>>>>>>>> > #+EMAIL: mailto:your-email@server.com
>>>>>>>>> > #+BABEL: :session *R* :cache yes :results output graphics :exports both
>>>>>>>>> :tangle yes
>>>>>>>>> >
>>>>>>>>> > * Example of Org-Babel for R Literate Programming
>>>>>>>>> > ** R text output
>>>>>>>>> > A simple summary.
>>>>>>>>> > #+begin_src R
>>>>>>>>> > x <- rnorm(10)
>>>>>>>>> > summary(x)
>>>>>>>>> > #+end_src
>>>>>>>>> >
>>>>>>>>> > ** R graphics output
>>>>>>>>> > Note we use the object =x= generated in previous code block, thanks to
>>>>>>>>> > the header option =:session *R*=. The output graphics file is
>>>>>>>>> > =a.png=.
>>>>>>>>> >
>>>>>>>>> > #+begin_src R :file a.png
>>>>>>>>> > y <- rnorm(10)
>>>>>>>>> > plot(x, y)
>>>>>>>>> > #+end_src
>>>>>>>>> >
>>>>>>>>> > Same plot with larger dimension:
>>>>>>>>> >
>>>>>>>>> > #+begin_src R :file b.png :width 800 :height 800
>>>>>>>>> > plot(x, y)
>>>>>>>>> > #+end_src
>>>>>>>>> > Where do I wrong?BestRiccardo
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Thomas S. Dye
>>>>>>>>> http://www.tsdye.com
>>>>>>>>>
>>>>>>>> Hi, this is the URL:http://orgmode.org/worg/org-contrib/babel/how-to-use-Org-Babel-for-R.htmlBestR
>>>>>>>> 2012/2/5 Thomas S. Dye <span dir="ltr"><mailto:tsd@tsdye.com></span>Hi Riccardo,
>>>>>>>>
>>>>>>>>
>>>>>>>> This code appears to be outdated. I don't recall this code on the org
>>>>>>>> site. Could you send a URL?
>>>>>>>>
>>>>>>>> All the best,
>>>>>>>> Tom
>>>>>>>>
>>>>>>>> Riccardo Romoli <mailto:ric.romoli@gmail.com> writes:
>>>>>>>>
>>>>>>>>> Hi, I'm trying to generate some figure with R, into an org session. Firstly
>>>>>>>>> I use the code in the org site. The problem is that the code do not
>>>>>>>>> generate any figure.
>>>>>>>>>
>>>>>>>>> This is the code:
>>>>>>>>>
>>>>>>>>> #+TITLE:Test
>>>>>>>>> #+AUTHOR: Your Name
>>>>>>>>> #+EMAIL: mailto:your-email@server.com
>>>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports
>>>>>>>>> both :tangle yes
>>>>>>>>>
>>>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>>>> ** R text output
>>>>>>>>> A simple summary.
>>>>>>>>> #+begin_src R
>>>>>>>>> x <- rnorm(10)
>>>>>>>>> summary(x)
>>>>>>>>> #+end_src
>>>>>>>>>
>>>>>>>>> ** R graphics output
>>>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>>>> =a.png=.
>>>>>>>>>
>>>>>>>>> #+begin_src R :file a.png
>>>>>>>>> y <- rnorm(10)
>>>>>>>>> plot(x, y)
>>>>>>>>> #+end_src
>>>>>>>>>
>>>>>>>>> Same plot with larger dimension:
>>>>>>>>>
>>>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>>>> plot(x, y)
>>>>>>>>> #+end_src
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Where do I wrong?
>>>>>>>>>
>>>>>>>>> Best
>>>>>>>>> Riccardo
>>>>>>>>> Hi, I'm trying to generate some figure with R, into an org
>>>>>>>>> session. Firstly I use the code in the org site. The problem is
>>>>>>>>> that the code do not generate any figure. This is the code:
>>>>>>>>> #+TITLE:Test
>>>>>>>>> #+AUTHOR: Your Name
>>>>>>>>> #+EMAIL: mailto:mailto:your-email@server.com
>>>>>>>>> #+BABEL: :session *R* :cache yes :results output graphics :exports both :tangle yes
>>>>>>>>>
>>>>>>>>> * Example of Org-Babel for R Literate Programming
>>>>>>>>> ** R text output
>>>>>>>>> A simple summary.
>>>>>>>>> #+begin_src R
>>>>>>>>> x <- rnorm(10)
>>>>>>>>> summary(x)
>>>>>>>>> #+end_src
>>>>>>>>>
>>>>>>>>> ** R graphics output
>>>>>>>>> Note we use the object =x= generated in previous code block, thanks to
>>>>>>>>> the header option =:session *R*=. The output graphics file is
>>>>>>>>> =a.png=.
>>>>>>>>>
>>>>>>>>> #+begin_src R :file a.png
>>>>>>>>> y <- rnorm(10)
>>>>>>>>> plot(x, y)
>>>>>>>>> #+end_src
>>>>>>>>>
>>>>>>>>> Same plot with larger dimension:
>>>>>>>>>
>>>>>>>>> #+begin_src R :file b.png :width 800 :height 800
>>>>>>>>> plot(x, y)
>>>>>>>>> #+end_src
>>>>>>>>> Where do I wrong?BestRiccardo
>>>>>>>>
>>>>>>>> <span class="HOEnZb">--
>>>>>>>> Thomas S. Dye
>>>>>>>> http://www.tsdye.com
>>>>>>>> </span>
>>>>
>>>>
>>>> Footnotes:
>>>> [1] http://orgmode.org/worg/org-contrib/babel/languages.html
--
Eric Schulte
http://cs.unm.edu/~eschulte/
^ permalink raw reply [flat|nested] 17+ messages in thread
end of thread, other threads:[~2012-02-18 21:53 UTC | newest]
Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-04 22:52 Generating plot with org-babel-R Riccardo Romoli
2012-02-04 23:37 ` Thomas S. Dye
2012-02-05 11:08 ` Riccardo Romoli
2012-02-05 16:45 ` Thomas S. Dye
2012-02-05 19:29 ` Updating the Babel section of Worg Was: " Eric Schulte
2012-02-06 5:43 ` Thomas S. Dye
2012-02-06 21:20 ` Updating the Babel section of Worg Eric Schulte
2012-02-08 0:01 ` Thomas S. Dye
2012-02-08 1:04 ` Martyn Jago
2012-02-08 14:21 ` Eric Schulte
2012-02-08 14:44 ` Rainer M Krug
2012-02-08 15:27 ` Eric Schulte
2012-02-08 14:14 ` Eric Schulte
2012-02-09 17:20 ` Thomas S. Dye
2012-02-18 21:53 ` Eric Schulte
2012-02-08 15:41 ` John Hendy
2012-02-06 21:12 ` Generating plot with org-babel-R Riccardo Romoli
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.