Hi all, I have a simple problem, bu don't find the solution: I like to count not-empty fields in Collect (number of height measurements per plot, where height is not measured for all trees). I tried idm:not-blank() in the Apply when field, but still I get the number of trees (all) instead the number of height measurements. Any hint is welcome!

Thanks, Lutz

asked 20 Feb '18, 10:13

Fehrmann's gravatar image

Fehrmann
7731532
accept rate: 0%


Hi Lutz,

if I remember right, 'Apply when' does not work with functions, see answer at https://openforis.support/questions/1301/table-type-entity-how-to-check-sum-of-attributes-in-a-column

This might work for entity 'tree':

count(tree[idm:not-blank(tree_height)])

But if you want that 0 is regarded as missing height value, then use this

count(tree[tree_height>0])

Regards, Lauri

permanent link

answered 24 Feb '18, 13:14

Lauri%20%28OF%29's gravatar image

Lauri (OF) ♦♦
6652815
accept rate: 21%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×493

question asked: 20 Feb '18, 10:13

question was seen: 2,839 times

last updated: 24 Feb '18, 13:14