all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Eric Schulte" <schulte.eric@gmail.com>
To: Org-mode <emacs-orgmode@gnu.org>
Subject: Feature-Request/Question: how to apply a calc/elisp function to a column in org-column-view
Date: Wed, 08 Oct 2008 18:57:17 -0700	[thread overview]
Message-ID: <8763o21qf6.fsf@gmail.com> (raw)

Hi,

In columnview, I'm looking to be able to apply a calc/elisp function to
a columns values before the column view is generated.  This is
specifically for columnviews captured in tables.

  (see info:org:Capturing column view)

This has come up before, and Carsten was nice enough to make it possible
to recalculate the column view automatically using an existing #+TBLFM
line inside the columnview dynamic block.

However, I would like to *replace* a column's value with a calculated
result.  This is because I am sometimes storing very *large* lists as
properties (large enough that Emacs chokes when trying to manage tables
with such large cells), and then trying to use columnview to generate
tables of calculated properties of these lists.

I realize that this is both an edge-case and a bastardization of the
intended use of columnview, and I would be happy to put the required
effort into implementing such a feature, but I have become tangled in
the columnview code, and don't know where I should look to insert this
functionality.

I was thinking this should be part of either
`org-dblock-write:columnview', or `org-columns', and then I noticed
`org-columns-compute-all' which seemed promising but upon inspection was
somewhat opaque.

Could anyone familiar with org-colview.el point me in the right
direction?

Should I just abandon the use of columnview for this task, and instead
write an independent function which sucks in the properties and spits
out the table?

Many Thanks -- Eric

As a "simple" example see below, I'd like to be able to generate the
given table using the given #+COLUMNS line (or something like it)

* example

#+COLUMNS:  %ITEM %d %f %=f+d
#+BEGIN: columnview :id "results"
| ITEM        |  d | f | f+d |
|-------------+----+---+-----|
| *** Results |    |   |     |
| **** run1   | 33 | 2 |  35 |
| **** run2   | 34 | 2 |  36 |
| **** run3   | 35 | 2 |  37 |
| **** run4   | 36 | 2 |  38 |
#+END:


** Results
   :PROPERTIES:
   :ID:       results
   :END:

*** run1
   :PROPERTIES:
   :d: 33
   :f: 2
   :END:

*** run2
   :PROPERTIES:
   :d: 34
   :f: 2
   :END:

*** run3
   :PROPERTIES:
   :d: 35
   :f: 2
   :END:

*** run4
   :PROPERTIES:
   :d: 36
   :f: 2
   :END:

             reply	other threads:[~2008-10-09  1:57 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-09  1:57 Eric Schulte [this message]
2008-10-09  5:35 ` Feature-Request/Question: how to apply a calc/elisp function to a column in org-column-view Carsten Dominik

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:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

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

  git send-email \
    --in-reply-to=8763o21qf6.fsf@gmail.com \
    --to=schulte.eric@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* 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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.