rle-methods: Miscellaneous Common Methods for 'rle' Objects

Description Usage Arguments Note Examples

Description

Miscellaneous Common Methods for rle Objects

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## S3 method for class 'rle'
c(...)

## S3 method for class 'rle'
mean(x, na.rm = FALSE, ...)

## S3 method for class 'rle'
length(x)

## S3 method for class 'rle'
is.na(x)

## S3 method for class 'rle'
str(object, ...)

Arguments

...

For c, objects to be concatenated. The first object must be of class rle.

x, object

An rle object.

na.rm

Whether missing values are to be ignored (TRUE) or propagated (FALSE).

Note

The length method returns the length of the vector represented by the object, obtained by summing the lengths of individual runs. This can be overridden by setting options(rle.unclass_index = FALSE), which causes it to return the length of the underlying representation (usually 2) instead.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20

statnet/rle documentation built on Jan. 5, 2021, 3:31 a.m.