emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Carsten Dominik <dominik@science.uva.nl>
To: Carsten Dominik <dominik@science.uva.nl>
Cc: Tassilo Horn <tassilo@member.fsf.org>, emacs-orgmode@gnu.org
Subject: Re: Spreadsheet question
Date: Fri, 5 Dec 2008 13:23:07 +0100	[thread overview]
Message-ID: <D56C4139-3421-4A5E-A7B7-2C48CB0ED8D8@uva.nl> (raw)
In-Reply-To: <4B5CC0DE-9FFB-4D8E-BC03-2D1F6D9359BA@uva.nl>

Actually, thinking more about this, I think that Tassilo is right.

Therefore, from now on, this condition will throw an error.
I would like to make this #ERROR in the table cell, but
this is not easy, so for the time being, it really stops
the evaluation with an error message.

Thanks, Tassilo, for pointing to this issue.

- Carsten

On Dec 5, 2008, at 8:26 AM, Carsten Dominik wrote:

> Hi Tassilo,
>
> I can see that this could be confusing, and maybe it should throw an  
> error.
>
> The use-ase fo this are running means as column formulas
> that would be undefined for he first few rows in.  Consider
> the following table:
>
>
> | i | nn | mean of last 3 |
> |---+----+----------------|
> | 1 |  4 |           4.00 |
> | 2 |  7 |           5.50 |
> | 3 |  2 |           4.33 |
> | 4 |  4 |           4.33 |
> | 5 |  5 |           3.67 |
> | 6 |  7 |           5.33 |
> | 7 |  9 |           7.00 |
> | 8 | 22 |          12.67 |
> #+TBLFM: $3=vmean([@-2$-1..$-1]);%.2f
>
> I am not sure how common this use is and who would
> be hurt by turning this behavior into an error.
>
> - Carsten
>
> On Dec 4, 2008, at 11:49 AM, Tassilo Horn wrote:
>
>> Carsten Dominik <dominik@science.uva.nl> writes:
>>
>> Hi Carsten,
>>
>>> @-1 references the row above the current.  If that is a hline, if
>>> actually references the current line.
>>
>> Yes, I see that, but I wonder if that's actually the right thing to  
>> do.
>> IMO defaulting to some cell/row/column which is not referenced  
>> correctly
>> might obscure wrong formulas.
>>
>> For example, in my case the first calculation gave 2 which is correct
>> and only the second recalculation shows me that the forumla is wrong.
>> So I'd prefer an #ERROR if a reference doesn't exist.
>>
>> Bye,
>> Tassilo
>

      reply	other threads:[~2008-12-05 12:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-03 21:34 Spreadsheet question Tassilo Horn
2008-12-04  8:06 ` Carsten Dominik
2008-12-04 10:49   ` Tassilo Horn
2008-12-05  7:26     ` Carsten Dominik
2008-12-05 12:23       ` Carsten Dominik [this message]

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

  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=D56C4139-3421-4A5E-A7B7-2C48CB0ED8D8@uva.nl \
    --to=dominik@science.uva.nl \
    --cc=emacs-orgmode@gnu.org \
    --cc=tassilo@member.fsf.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 public inbox

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

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).