emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] Calc: Second to last row


From: Nick Dokos
Subject: Re: [O] Calc: Second to last row
Date: Wed, 31 Aug 2016 18:21:09 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux)

Karl Voit <address@hidden> writes:

> Hi!
>
> I would like to refer to the second to last row of a table.
>
> The following example should demonstrate my issue. What I expect is
> that the following formula is filling @address@hidden with "1" and in the
> last row, there is the sum of all "1".
>
> It is important to me to ignore the number of horizontal lines since
> their number varies in my case.
>
> | Values |
> |--------|
> |        |
> |        |
> |--------|
> |        |
> |        |
> |--------|
> |        |
>
> #+TBLFM: @2$1..@>-1$1=1 :: @>$1=vsum(@2$1..@>-1$1)

This should be:

#+TBLFM: @2$1..@>>$1=1 :: @>$1=vsum(@2$1..@>>$1)

>
> Expected result:
>
> | Values |
> |--------|
> |      1 |
> |      1 |
> |--------|
> |      1 |
> |      1 |
> |--------|
> |      4 |
>
> Actual result: "user-error: Several field/range formulas try to set
> @8$1".
>
> With a fixed number of horizontal lines, the sum would be:
>
> #+TBLFM: @>$1=vsum(@address@hidden);T
>
> So how can this be accomplished for an arbitrary number of
> horizontal lines?
>
>
> At my side: Org-mode version 8.3.4 (release_8.3.4-33-gd522fc)

-- 
Nick




reply via email to

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