From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christian Wittern Subject: help with porting babel example on worg to latest version Date: Mon, 06 Jan 2014 16:03:05 +0900 Message-ID: <52CA5529.2050705@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:56981) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W04DU-0005Wg-Us for emacs-orgmode@gnu.org; Mon, 06 Jan 2014 02:03:22 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1W04DP-0005Rq-8L for emacs-orgmode@gnu.org; Mon, 06 Jan 2014 02:03:16 -0500 Received: from mail-pb0-x231.google.com ([2607:f8b0:400e:c01::231]:41042) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W04DP-0005R9-0V for emacs-orgmode@gnu.org; Mon, 06 Jan 2014 02:03:11 -0500 Received: by mail-pb0-f49.google.com with SMTP id jt11so17900947pbb.8 for ; Sun, 05 Jan 2014 23:03:08 -0800 (PST) Received: from mbp3a-2.local (chw.zinbun.kyoto-u.ac.jp. [130.54.104.146]) by mx.google.com with ESMTPSA id g6sm165720778pat.2.2014.01.05.23.03.07 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 05 Jan 2014 23:03:07 -0800 (PST) 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: Org Mode Mailing List Hi there, I am trying to understand how to use information from an org table as input for a babel function. For this purpose, I looked at the example at http://orgmode.org/worg/org-contrib/babel/intro.html#arguments-to-source-code-blocks It seems that this is using the old syntax, eg. #+tblname, which seems to be just #+name now. But even with this change I can not reproduce the result. With the following code, I get the message "Symbol's value as variable is void: fib-inputs" when doing C-c on the src. I am sure there are more changes I need to make, but I can't figure it out. Any help appreciated. Here is the code so far: #+name: fibonacci-inputs | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | | 2 | 4 | 6 | 8 | 10 | 12 | 14 | 16 | 18 | 20 | #+name: fibonacci-seq(fib-inputs=fibonacci-inputs) #+begin_src emacs-lisp (defun fibonacci (n) (if (or (= n 0) (= n 1)) n (+ (fibonacci (- n 1)) (fibonacci (- n 2))))) (mapcar (lambda (row) (mapcar #'fibonacci row)) fib-inputs) #+end_src All the best, Christian -- Christian Wittern, Kyoto