Learn R Programming

in2extRemes (version 1.0-3)

as.in2extRemesDataObject: Convert Data Frame Object to in2extRemes Data Object

Description

Convert a data frame, matrix or vector into an object readable by the in2extRemes windows.

Usage

as.in2extRemesDataObject(x)

Arguments

x
data frame, matrix or numeric vector.

Value

A list of class “in2extRemesDataObject” with component:

Details

Sets up a list object with a data component that contains the datafram x, or if x is a matrix or vector, it is first converted to a data frame using as.data.frame. If x is a vector, an additional column, named “obs”, is added that contains an index of the row number. It is then given the class “in2extRemesDataObject” and returned.

See Also

as.data.frame

Examples

Run this code

look <- apply(matrix(rnorm(100 * 100), 100, 100), 2, max, na.rm = TRUE)
look2 <- as.in2extRemesDataObject(look)

Run the code above in your browser using DataLab