emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Juan Manuel Macías" <maciaschain@posteo.net>
To: Roger Mason <rmason@mun.ca>
Cc: orgmode <emacs-orgmode@gnu.org>
Subject: Re: return column from table as a column
Date: Fri, 13 Aug 2021 17:12:46 +0000	[thread overview]
Message-ID: <87fsvd6zg1.fsf@posteo.net> (raw)
In-Reply-To: <y65wnopl2zk.fsf@mun.ca> (Roger Mason's message of "Fri, 13 Aug 2021 14:02:31 -0230")

Hello Roger,

Roger Mason writes:

> Thank you, I think I may be able to get this to work.

You're welcome. Just a minor fix: although the code works fine,
naturally the asterisk in `let' was unnecessary. This is a new version
with the code explained, in case you find it useful:

#+begin_src emacs-lisp :var data=s1 col=3
  (let* (
	 ;; return a list from elemens in column number `col'
	 (list-from-column (mapcar (lambda (r) (format "%s" (nth col r))) data))
	 ;; make a list of lists = a new table that contains one single column
	 (new-table (mapcar 'list list-from-column)))


Juan Manuel 

  reply	other threads:[~2021-08-13 17:13 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-13 14:17 return column from table as a column Roger Mason
2021-08-13 14:30 ` Greg Minshall
2021-08-13 16:24   ` Roger Mason
2021-08-13 18:47   ` Greg Minshall
2021-08-13 14:47 ` Juan Manuel Macías
2021-08-13 16:32   ` Roger Mason
2021-08-13 17:12     ` Juan Manuel Macías [this message]
2021-08-14 10:30       ` Roger Mason
2021-08-14 12:10 ` Maxim Nikulin
2021-08-17 20:42   ` Roger Mason

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87fsvd6zg1.fsf@posteo.net \
    --to=maciaschain@posteo.net \
    --cc=emacs-orgmode@gnu.org \
    --cc=rmason@mun.ca \


* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).