On Mon, Feb 28, 2011 at 9:35 AM, Rustom Mody <rustompmody@gmail.com> wrote:
When using orgmode for hacking on data in a table (org a la spreadsheet)  I have this situation
Say I am concentrating on column 2 and I want the bottom cell to be the sum of the above cells
For a 7 row table with 8th row having the total I get

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

But now I have a problem: If say I add a row to the table then the next time I recompute the formula(s) the ninth row is not affected and the 8th row which is now data gets overwritten with a computation.

So basically I want the @1 and @7 which are hardcoded above to be replaced by something to the effect: "everything above..." and the @8$2 should be something to the tune of "bottom of $2"

Place the rows you want to sum between horizontal separator lines (see http://orgmode.org/manual/Built_002din-table-editor.html#Built_002din-table-editor)

Then you can do the following:

  #+TBLFM: @8$2=vsum(@I..@II)

Which means, sum the columns between the first and the second separators.

-Luke