Learn R Programming

hmi (version 0.9.16)

sna_interval: Get standard NAs from interval data

Description

This function replaces observations with "-Inf;Inf" in an interval, which basically means "no information available", with the standard NAs (therefore the name 'sna'). Observations with a finite bound (e.g.x = "0;Inf") are not replaced, since they contain information (here: "x is positive").

Usage

sna_interval(x)

Arguments

x

can by any object, but the function was designed for interval-objects.

Value

In case of x being an interval-object, it returns a n times 2 matrix. The first column is the lower bound, the second the upper bound. Otherwise it returns just x.