emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] Output result of source block to a file


From: Roger Mason
Subject: Re: [O] Output result of source block to a file
Date: Thu, 06 Jun 2019 09:06:31 -0230
User-agent: mu4e 1.1.0; emacs 26.1

Hello,

stardiviner <address@hidden> writes:

> Roger Mason <address@hidden> writes:
>
>> Hello,
>>
>> I want to output the result of the evaluation of a (python) source block
>> to a (graphics) file and have a link to the file inserted in the buffer.

>> #+begin_src python :results value file :file scaleplot02.pdf :exports 
>> results :var data=test

...snip...

>>   plt.savefig(file)
>>   print ("[[./%s]]" % file)
>> #+end_src

> For this, you should try updated header arguments like ":results graphics 
> link"
> or ":results file link".

Thanks for your reply.

The current incarnation:

#+begin_src python :results graphics link :exports results :var data=test :var 
file="scaleplot2.pdf"

The output:
#+RESULTS: scaleplot02
: None

I'm guessing I have the syntax wrong.  Is it documented somewhere?  I'm
on Org mode version 9.1.13 (release_9.1.13-784-ged7d1d @
/home/rmason/.emacs.d/org-git/lisp/).

Cheers,
Roger



reply via email to

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