https://github.com/cran/Epi
Tip revision: c19f4fa9ac00eb596ebc275a5ef6c757a2fc32d7 authored by Bendix Carstensen on 14 May 2013, 00:00:00 UTC
version 1.1.49
version 1.1.49
Tip revision: c19f4fa
start.Lexis.Rd
\name{start.Lexis}
\alias{entry}
\alias{exit}
\alias{status}
\alias{dur}
\title{Time series methods for Lexis objects}
\description{
Extract the entry time, exit time, status or duration of follow-up from a
\code{Lexis} object.
}
\usage{
entry(x, time.scale = NULL, by.id=FALSE)
exit(x, time.scale = NULL, by.id=FALSE)
status(x, at="exit" , by.id=FALSE)
dur(x, by.id=FALSE)
}
\arguments{
\item{x}{an object of class \code{Lexis}.}
\item{time.scale}{a string or integer indicating the time scale. If
omitted, all times scales are used.}
\item{by.id}{Logical, if \code{TRUE}, only one record per unique value
of \code{lex.id} is returned; either the first, the last or for
\code{dur}, the sum of \code{lex.dur}. If \code{TRUE}, the returned
object have the \code{lex.id} as (row)nmes attribute.}
\item{at}{string indicating the time point(s) at which status is to be
measured.}
}
\value{
The \code{entry} and \code{exit} functions return a vector of
entry times and exit times, respectively, on the requested time
scale. If multiple time scales are requested, then a matrix is
returned.
The \code{status} function returns a vector giving the status
at entry or exit and \code{dur} returns a vector with the lengths
of the follow-up intervals.
}
\author{Martyn Plummer}
\seealso{\code{\link{Lexis}}}
\keyword{survival}
\keyword{ts}