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

datagrabber

Get Original Data from an R Object


Description

Get the original data set used to obtain the resulting R object for which a method function exists.

Usage

## S3 method for class 'declustered'
datagrabber(x, ...)

## S3 method for class 'extremalindex'
datagrabber(x, ...)

## S3 method for class 'fevd'
datagrabber(x, response = TRUE,
    cov.data = TRUE, ...)

Arguments

x

An R object that has a method function for datagrabber.

response, cov.data

logical; should the response data be returned? Should the covariate data be returned?

...

optional arguments to get. This may eventually become deprecated as scoping gets mixed up, and is currently not actually used.

Details

Accesses the original data set from a fitted fevd object or from declustered data (objects of class “declustered”) or from extremalindex.

Value

The original pertinent data in whatever form it takes.

Author(s)

Eric Gilleland

See Also

Examples

y <- rnorm(100, mean=40, sd=20)
y <- apply(cbind(y[1:99], y[2:100]), 1, max)
bl <- rep(1:3, each=33)

ydc <- decluster(y, quantile(y, probs=c(0.95)), r=1, blocks=bl)

yorig <- datagrabber(ydc)
all(y - yorig == 0)

extRemes

Extreme Value Analysis

v2.1
GPL (>= 2)
Authors
Eric Gilleland
Initial release
2020-11-20

We don't support your browser anymore

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