emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Neil Jerram <neiljerram@gmail.com>
To: Nathan Neff <nathan.neff@gmail.com>
Cc: emacs-orgmode <emacs-orgmode@gnu.org>
Subject: Re: Tables: Exclude headings in Row Number?
Date: Thu, 19 Sep 2019 15:13:01 +0100	[thread overview]
Message-ID: <CAKuG=vvsP1b+rDLJBir8Hq4raGAwd=VNKrHfS1cUTvgTYC_1Sg@mail.gmail.com> (raw)
In-Reply-To: <CAC=HedAXC-R_7558nXcCBZpm5bM7G69_T9047uz7w3bMJzMFtQ@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1296 bytes --]

Does this answer your question?

#+NAME: tt
| num | ID |
|-----+----|
|   1 | A  |
|   2 | B  |
|   3 | C  |
|   4 |    |
|   5 | E  |

#+BEGIN_SRC emacs-lisp :var tt=tt
(length tt)
#+END_SRC

#+RESULTS:
: 5

Best wishes,
    Neil


On Wed, 18 Sep 2019 at 18:39, Nathan Neff <nathan.neff@gmail.com> wrote:

> Hello all,
>
> I have a table like this:
>
>
> | ID |
> |----|
> |  2 |
> |  3 |
>
> and I want to know how many rows there are w/o the ID heading
> and w/o the horizontal separator.  I found the
> org-table-toggle-coordinate-overlays
> which displays an overlay showing the row number:
>
> https://www.evernote.com/l/AOJvD5ty6RRIBYAcSWV-047CKCHT5NIAhl8
>
> However, the heading is included in the row number (which makes sense).
>
> Is there a way to ignore lines above a heading (or mark a heading in some
> way?
>
> I found a way to add a seq. number by using Calc [1] but I was wondering if
> there's a way to tell the org-table-toggle-coordinate-overlays not to
> count the
> heading.
>
> Thanks,
> --Nate
>
> [1]
>
>
> | num | ID |
> |-----+----|
> |   1 | A  |
> |   2 | B  |
> |   3 | C  |
> |   4 |    |
> |   5 | E  |
> #+TBLFM: $1=vlen(@I..0)
>
>
> https://stackoverflow.com/questions/9267050/how-to-achieve-a-row-index-column-in-emacs-org-mode-using-a-calc-column-rule
>
>
>

[-- Attachment #2: Type: text/html, Size: 2501 bytes --]

  reply	other threads:[~2019-09-19 14:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-18 17:07 Tables: Exclude headings in Row Number? Nathan Neff
2019-09-19 14:13 ` Neil Jerram [this message]
2019-09-23  3:22   ` Nathan Neff
2019-09-23  3:24     ` Nathan Neff
2019-09-27  0:45       ` Neil Jerram

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='CAKuG=vvsP1b+rDLJBir8Hq4raGAwd=VNKrHfS1cUTvgTYC_1Sg@mail.gmail.com' \
    --to=neiljerram@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=nathan.neff@gmail.com \
    /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).