-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 01/03/2011 04:19, Rustom Mody wrote: > Nick Dokos wrote: > >> Of course it's reasonable - and of course, org implements it >> #+TBLFM: $LR2=vsum(@1..@-1) > > Thanks Nick I can use that. But I dont understand it. What's the -1? > The manual says -- relative to 'current' column. > What determines 'current?' There must be some obvious POV which I am > missing...
@X = row X, absolute. @-X = X rows before, relative. For instance : I*1 |A--| 1| 1 | 2| 2 | 3| 3 | I*2 |A--| 4| 6 | I*3 |A--| #+TBLFM: $1=vsum(@1..@-1) Here the 4th row is the sum. So @-1refers to the 3rd row. If we add a new row before, the sum still works. I*1 |A---| 1| 1 | 2| 2 | 3| 3 | 4| 42 | I*2 |A---| 5| 48 | I*3 |A---| #+TBLFM: $1=vsum(@1..@-1) @-1 now refers to the 4 row. - -- freely yours, theo -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEcBAEBAgAGBQJNbHjoAAoJECkgngj8k9TvPggIAKXvaaz4HfzPOiU2RAajBqYq /qFYvk5Pf3e1QJme8qiiY0JWiW6isS+YI7bg9Hg6XLe5F3qxm20zz3Z008jWyZuN TBhsr6ox0B3Hf3OnienQrhUvm8v1bIWiEhJFd/qBG0mp8dY5zeuJro6bLWrZxKhn zVO0dw7rh3xQoYIOzRIoP1wnykg2xw3st4GH4JqdSusLhAwy/AfkvjgXBf3qbZ/p FU8ksalYgQUb9S+GGpFdzIyPqJ+d7m3JbAQHbZ0Wpak0oCR306BGIcBuqMqzAZCd 5ukuHJr+Ug4Mlt+OjreAJajeMUVAYTSCU46nupuEJysK4egKEz0LLcNPzoXr7BU= =o6Qk -----END PGP SIGNATURE----- -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode