Learn R Programming

hmi (version 0.9.16)

as.interval: Function to transform objects into an interval object

Description

Function to transform numeric (or character) vectors or n times 2 matrices into an interval object

Usage

as.interval(x, sna = FALSE)

Arguments

x

An object to transform. Currently the function can transform numeric vectors and characters

sna

Boolean: if TRUE, NAs are kept as standard NAs. Otherwise they are turned into "-Inf;Inf".

Value

A vector of class interval.

See Also

generate_interval

Examples

Run this code
# NOT RUN {
as.interval(c("1000;2000", "700;700", NA))
# }

Run the code above in your browser using DataLab