Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

flip-methods

Methods for function flip in Package NADA


Description

Methods for function flip in package NADA.

When used in concert with Cen, flip rescales left-censored data into right-censored data for use in the survival package routines (which can only handle right-censored data sets).

Usage

## S4 method for signature 'Cen'
flip(x)

## S4 method for signature 'formula'
flip(x)

Arguments

x

A Cen or formula object.

Notes

Flips, or rescales a Cen object or a formula object.

By default, flip rescales the input data by subtracting a large constant that is larger than maximum input value from all observations. It then marks the data as right censored so that routines from the survival package can be used.

IMPORTANT: All NADA routines transparently handle flipping and re-transforming data. Thus, flip should almost never be used, except perhaps in the development of an extension function.

Also, flipping a Cen object results in a Surv object – which presently cannot be flipped back to a Cen object!

Flipping a formula just symbolically updates the response (which should be a Cen object). Result is like: flip(Cen(obs, cen))~groups


NADA

Nondetects and Data Analysis for Environmental Data

v1.6-1.1
GPL (>= 2)
Authors
Lopaka Lee
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.