as.data.frame.incidence2: Convert incident object to a data frame

View source: R/as.data.frame.R

as.data.frame.incidence2R Documentation

Convert incident object to a data frame

Description

Convert incident object to a data frame

Usage

## S3 method for class 'incidence2'
as.data.frame(x, row.names, optional, ...)

Arguments

x

incidence2 object.

row.names

Not used.

optional

Not used.

...

Not used.

See Also

as.data.frame for the underlying generic.

Examples


dat <- data.frame(
    dates = Sys.Date() + 1:100,
    names = rep(c("Jo", "John"), 5)
)

dat <- incidence(dat, date_index = "dates", groups = "names")
as.data.frame(dat)



incidence2 documentation built on Oct. 7, 2024, 1:07 a.m.