From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Schulte Subject: Re: using gnuplot's "splot" and "every" commands on org-mode table data Date: Mon, 13 May 2013 15:38:53 -0600 Message-ID: <87ip2mpnki.fsf@gmail.com> References: <87k3ncxeqt.fsf@gmail.com> <87y5bpocz9.fsf@gmail.com> <87hai858qc.fsf@Rainer.invalid> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([208.118.235.92]:32972) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uc0Sh-0005Ka-5i for emacs-orgmode@gnu.org; Mon, 13 May 2013 17:39:16 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Uc0Sg-0005xT-5Q for emacs-orgmode@gnu.org; Mon, 13 May 2013 17:39:15 -0400 Received: from mail-da0-x22f.google.com ([2607:f8b0:400e:c00::22f]:55559) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uc0Sf-0005xJ-V9 for emacs-orgmode@gnu.org; Mon, 13 May 2013 17:39:14 -0400 Received: by mail-da0-f47.google.com with SMTP id k13so1550968dae.6 for ; Mon, 13 May 2013 14:39:12 -0700 (PDT) In-Reply-To: <87hai858qc.fsf@Rainer.invalid> (Achim Gratz's message of "Sun, 12 May 2013 20:55:07 +0200") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Achim Gratz Cc: emacs-orgmode@gnu.org Achim Gratz writes: > Eric Schulte writes: >> This does look like a bug to me. Can you isolate "where" the value of >> data in your example is first assigned the wrong value? > > The error lies in how ob-sh tries to determine if it needs to process a > table or a vector and then forgets to check for 'hline, thus ending up > in the vector branch with the table data. > >> Thanks for reporting. I will save your example for when I next have >> development time. > > Here's a suggestion for a quick fix. I've also implemented :hlines > processing for ob-sh (it was ignoring that header arg unconditionally) > and added an experimental header arg :hline-string to control how hlines > get actually exported. BTW, trailing blank lines in the output get > swallowed when re-importing to Org, I'm not sure if that is supposed to > happen or not. > This looks great. Please go ahead and apply this patch to ob-sh. > > Giving ob-gnuplot (and possible ob-awk, which also uses > orgtbl-to-generic) a similar treatment would allow to do this directly > without going through ob.sh of course. > That sounds like a good solution to me. Generally whenever a solution may be made in a generic support function instead of a language specific file I would consider that a win. If you have a good implementation here I'd be very happy if you applied it. Cheers, > > Regards, > Achim. -- Eric Schulte http://cs.unm.edu/~eschulte