Re: where to place caption so babel results include caption?

2019-11-09 Thread Ken Mankoff
On 2019-11-06 at 17:53 +01, Ken Mankoff wrote... > On 2019-11-06 at 17:05 +01, Berry, Charles wrote... >> M-: (org-babel-map-src-blocks nil (org-babel-insert-result "" >> '("replace"))) RET An improvement: Don't insert #+results: if they don't already exist: (org-babel-map-src-blocks nil

Re: where to place caption so babel results include caption?

2019-11-06 Thread Ken Mankoff
On 2019-11-06 at 17:05 +01, Berry, Charles wrote... > M-: (org-babel-map-src-blocks nil (org-babel-insert-result "" > '("replace"))) RET > > HTH, Yes that helps! A simple solution. Thank you. -k.

Re: where to place caption so babel results include caption?

2019-11-06 Thread Berry, Charles
> On Nov 6, 2019, at 1:55 AM, Ken Mankoff wrote: > > Hello, > > If I have a babel block that generates a table and I'd like latex attributes > associated with that table, it seems to work well if I do this: > > #+NAME: foo > #+BEGIN_SRC bash :results table > echo "${RANDOM}|${RANDOM}|" >

[O] where to place caption so babel results include caption?

2019-11-06 Thread Ken Mankoff
Hello, If I have a babel block that generates a table and I'd like latex attributes associated with that table, it seems to work well if I do this: #+NAME: foo #+BEGIN_SRC bash :results table echo "${RANDOM}|${RANDOM}|" echo "${RANDOM}|${RANDOM}|" #+END_SRC #+caption: foo #+latex_attr: