emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Orgmode] [PATCH] Add min/max/mean age operators to column view.


From: James TD Smith
Subject: Re: [Orgmode] [PATCH] Add min/max/mean age operators to column view.
Date: Thu, 29 Oct 2009 21:15:43 +0000
User-agent: Mutt/1.5.20 (2009-06-14)

Hi Mikael,

On 2009-10-29 14:17:11(+0100), Mikael Fornius wrote:
> Maybe someone other than me should test this because I am not sure if I
> understand it correctly? 
> 
> The only reference to "age" or "creation time" I can find is in the
> documentation string of org-sort-entries-or-items.
> 
> "... creation time, which is assumed to be the first inactive time stamp
> at the beginning of a line."
 
Sorry, I could have been more specific in my description of what the patch does.
What it does is add three operators which can be applied to properties
containing timestamps, which show the length of time between the timestamp and
the current time for leaf entries, and either the minimum, maximum or average
elapsed time for entries with children.

The age/creation time thing is just a suggested usage. All my remember templates
add a CREATED property containing a timestamp, so by adding address@hidden to
the columns for a tree I can get a display of the time which has elapsed since
that item was added.

> I pulled from your git://yog-sothoth.mohorovi.cc/org-mode.git
> misc-new-features branch and have tried a basic setup with timestamps as
> described with no success. I must have missed something.
> 
> When I use org-columns-new (M-S-right/left) to add a column there is no
> choice named age or creation time, should I use TIMESTAMP_IA?
> 
> When I do I have three (new?) options "age, age, age" as summary options
> and I think it should be "min_age, mean_age, max_age" instead?

I didn't test org-columns-new much; I tend to set up columns manually using the
COLUMNS property. I'll have to take a look at that.
 
> When I manually tried to summarize a address@hidden I got just
> numbers when I expected a date.

You shouldn't see a date. You should see something like '22d 3h 4m 11s' giving
the time since the first inactive timestamp in each item, and if an item has
children the average of the values from the childen. 

If you have a file like:
--8<---------------cut here---------------start------------->8---
#+COLUMNS: %20ITEM address@hidden
* Test 1
  [2008-10-29 Thu 21:05]
* Test 2
  [2009-10-29 Thu 21:05]
* Test 3
** Test 4
   [2009-10-29 Thu 20:05]
** Test 5
   [2009-11-29 Thu 21:05]
--8<---------------cut here---------------end--------------->8---

You should see something like this (from the column view dblock):

--8<---------------cut here---------------start------------->8---
| ITEM      | TIMESTAMP_IA     |
|-----------+------------------|
| * Test 1  | 365d 00h 04m 01s |
|-----------+------------------|
| * Test 2  | 0d 00h 04m 01s   |
|-----------+------------------|
| * Test 3  | -31d 00h 04m 01s |
| ** Test 4 | 0d 01h 04m 01s   |
| ** Test 5 | -31d 00h 04m 01s |
--8<---------------cut here---------------end--------------->8---

> I also have another problem with org-columns-new that when selecting a
> summary type the #+COLUMNS row is not updated, format specification
> works. I do not know if this is introduced by this patch or some other
> but it used to work...

It's probably the patch.

Thanks for testing this, and also for the improvements you made to column view
which made this possible.

James

--
|-<James TD Smith>-<email/address@hidden>-|





reply via email to

[Prev in Thread] Current Thread [Next in Thread]