[Top][All Lists]

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

Re: [O] Creating hline in table from source block?

From: Achim Gratz
Subject: Re: [O] Creating hline in table from source block?
Date: Tue, 26 Nov 2013 21:07:39 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

Loris Bennett writes:
> No, the column names are fixed, so that's perfect, thank you.  I
> suspected there might be some more straight-forward way than the
> interesting, but slightly more involved methods suggested by Achim and
> Rasmus.

There might be way to do that, but it's not implemented for shell blocks
since there isn't an easy way to deal with arrays in a shell.  You'd be
much better off using a language that has support for that (like Perl).

In your case (when the first line is always a header and you don't need
hlines anywhere else), the following trick using the end header
arguments of a call line works just as well:

--8<---------------cut here---------------start------------->8---
#+NAME: table
#+BEGIN_SRC sh :results table
echo "a b c d"
echo "1 2 3 4"
echo "5 6 7 8"

#+CALL: table() :results table :colnames yes

| a | b | c | d |
| 1 | 2 | 3 | 4 |
| 5 | 6 | 7 | 8 |
--8<---------------cut here---------------end--------------->8---

+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+

SD adaptations for KORG EX-800 and Poly-800MkII V0.9:

reply via email to

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