Learn R Programming

genvar (version 0.0.2.0)

count: Counts how many observations (optionally, satisfying a condition)

Description

Counts how many observations (optionally, satisfying a condition)

Usage

count(ifstmt)

Arguments

ifstmt

an optional argument which gives an condition that must be met for the observation to be counted

Value

returns the count

Examples

Run this code
# NOT RUN {
use(cars, clear=TRUE)
count()
count(speed <= 20)
# }

Run the code above in your browser using DataLab