emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Orgmode][babel] Problem using noweb


From: Eric S Fraga
Subject: Re: [Orgmode][babel] Problem using noweb
Date: Wed, 09 Feb 2011 19:04:10 +0000
User-agent: Gnus/5.110011 (No Gnus v0.11) Emacs/24.0.50 (gnu/linux)

andy <address@hidden> writes:

> I want to take advantage of babel's noweb capabilities, but I can't seem
> to get it to work. I'm sure there is something trivial wrong with my
> source block, but after looking at the documentation and looking at the
> examples I can find on the web, I think this should work.
>
> I define a variable in test-block, but it's not there, even though
> test-block should be getting pulled in when I run the source block, bar.
> What am I doing wrong? My .emacs has R defined and indeed, the session
> *R* starts up without any problems and the print statement works, but
> test-block just isn't there.
>
> * Foo
> ** Bar
> #+src_name: bar
> #+begin_src R :noweb yes :session *R*
>   <<test-block>>
>   print("I am here")
>   a
> #+end_src
>
> * test-block
> #+src_name: test-block
> #+begin_src R :session *R*
>   a <- c(1,2,3,4,5)
> #+end_src
>
>
> thanks
> --andy

I believe that you need to specify noweb on every source block,
including the one you wish to include.  That's what I had to do, in any
case, if I remember correctly...  haven't tried it on your code as my
train is pulling into the station and I have to run! ;)

-- 
: Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.50.1
: using Org-mode version 7.4 (release_7.4.330.g7473e)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]