numberof: Count the number elements that satisfy a condition.

Description Usage Arguments Author(s) Examples

Description

numberof counts the number elements that satisfy a condition.

Usage

1
numberof(x, f)

Arguments

x

Numerical array.

f

Logical function emulating the condition to be satisfied.

Author(s)

Christian W. Hoffmann <christian@echoffmann.ch>

Examples

1
  numberof(c(1:100,NA,NA,NaN),function(x) !is.na(x))

cwhmisc documentation built on May 1, 2019, 7:55 p.m.