empty_vector_if_na {tern}R Documentation

Return an empty numeric if all elements are NA.

Description

Return an empty numeric if all elements are NA.

Usage

empty_vector_if_na(x)

Arguments

x

(numeric)
vector.

Value

An empty numeric if all elements of x are NA, otherwise x.

Examples

x <- c(NA, NA, NA)
# Internal function - empty_vector_if_na

[Package tern version 0.9.6 Index]