Skip to contents

Checks if a compact vector has been expanded

Usage

compact_is_expanded(x)

Arguments

x

An ALTREP vector of class compact_realseq or compact_intseq

Value

A logical scalar. TRUE if the vector is expanded, FALSE if it is compact

Examples

x <- 1:3
compact_is_expanded(x)
#> [1] FALSE
compact_expand(x)
compact_is_expanded(x)
#> [1] TRUE