From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rainer M Krug Subject: Wrong results from R source block when returning a list Date: Tue, 03 Nov 2015 13:08:37 +0100 Message-ID: Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:33582) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZtaOf-0004CZ-K7 for emacs-orgmode@gnu.org; Tue, 03 Nov 2015 07:09:06 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZtaOc-0004Yz-DH for emacs-orgmode@gnu.org; Tue, 03 Nov 2015 07:09:05 -0500 Received: from mail-wi0-f173.google.com ([209.85.212.173]:37529) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZtaOc-0004Rb-71 for emacs-orgmode@gnu.org; Tue, 03 Nov 2015 07:09:02 -0500 Received: by wicfv8 with SMTP id fv8so10164234wic.0 for ; Tue, 03 Nov 2015 04:08:40 -0800 (PST) Received: from Rainers-MacBook-Pro.local (arn78-1-88-186-171-7.fbx.proxad.net. [88.186.171.7]) by smtp.gmail.com with ESMTPSA id wz7sm27242825wjc.26.2015.11.03.04.08.37 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 03 Nov 2015 04:08:38 -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: emacs-orgmode@gnu.org --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Hi The following code block returns a wrong table / list: #+begin_src R :results value list list(1:10, 1:5) #+end_src #+RESULTS: =2D (1 1) =2D (2 2) =2D (3 3) =2D (4 4) =2D (5 5) =2D (6 1) =2D (7 2) =2D (8 3) =2D (9 4) =2D (10 5) The result is actually in R: #+begin_src R :results output list(1:10, 1:5) #+end_src #+RESULTS: : [[1]] : [1] 1 2 3 4 5 6 7 8 9 10 :=20 : [[2]] : [1] 1 2 3 4 5 This is likely caused by the recycling rules in R, but it is actually wrong in the org context: The shown result is: #+begin_src R :results table list(1:10, 1:5) #+end_src #+RESULTS: | 1 | 1 | | 2 | 2 | | 3 | 3 | | 4 | 4 | | 5 | 5 | | 6 | 1 | | 7 | 2 | | 8 | 3 | | 9 | 4 | | 10 | 5 | Whil;e I would expect: #+RESULTS: | 1 | 1 | | 2 | 2 | | 3 | 3 | | 4 | 4 | | 5 | 5 | | 6 | | | 7 | | | 8 | | | 9 | | | 10 | | I have no idea if this is a bug or wrong result due to incompatible types (R list and org table)? Is this mentioned in the manual? Rainer =2D-=20 Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology,= UCT), Dipl. Phys. (Germany) Centre of Excellence for Invasion Biology Stellenbosch University South Africa Tel : +33 - (0)9 53 10 27 44 Cell: +33 - (0)6 85 62 59 98 Fax : +33 - (0)9 58 10 27 44 Fax (D): +49 - (0)3 21 21 25 22 44 email: Rainer@krugs.de Skype: RMkrug PGP: 0x0F52F982 --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEcBAEBCAAGBQJWOKPFAAoJENvXNx4PUvmCbpgH/AykV/JC/+mEi8sbE+WcLkhT 3TCvFI4dlhf/NXl/s9ym1hCSMwHr6QhAQTsnthJYH1d2g3/24U/IfIvqy1CvNdXD s3bJOIL/e6BZKIbpUxWgfH3gbQiIfRlIXWLsGeYgsBdhTPPkNvjeWVUIaxC/+a6A 17YMFpfpgwRroipbJhBgaMUpWsWnGpJufurFZZP4404WL0fstGgg9R8xBl1BWz8M b41wjHwac9Ddp6vqdw11lBUMFcD4FZiKXRHjIAuErWQtim4+avPsqtE8JPLhcAam a06JZ4JdlMO+T4iO/oPyEgVRdOwSQXmPz1JTjCiWFG5TvR8buJDjzUoVx+as5/Y= =lOzI -----END PGP SIGNATURE----- --=-=-=--