Learn R Programming

⚠️There's a newer version (2.11.5) of this package.Take me there.

eha (version 2.11.4)

Event History Analysis

Description

Parametric proportional hazards fitting with left truncation and right censoring for common families of distributions, piecewise constant hazards, and discrete models. Parametric accelerated failure time models for left truncated and right censored data. Proportional hazards models for tabular and register data. Sampling of risk sets in Cox regression, selections in the Lexis diagram, bootstrapping. Broström (2022) .

Copy Link

Version

Install

install.packages('eha')

Monthly Downloads

2,368

Version

2.11.4

License

GPL (>= 2)

Maintainer

Göran Broström

Last Published

March 8th, 2024

Functions in eha (2.11.4)

check.dist

Graphical goodness-of-fit test
check.surv

Check the integrity of survival data.
eha-package

eha: Event History Analysis
cro

Creates a minimal representation of a data frame.
child

Child mortality, Skellefteå, Sweeden 1850--1900.
Lognormal

The Lognormal Distribution
aftreg

Accelerated Failure Time Regression
HiscoHisclass

HISCO to HISCLASS transformation
Loglogistic

The Loglogistic Distribution
coxfunk

Loglihood function (partial likelihood) of a Cox regression
compHaz

Graphical comparison of cumulative hazards
infants

Infant mortality and maternal death, Sweeden 1821--1894.
Pch

The Piecewise Constant Hazards distribution.
coxreg.fit

Cox regression
join.spells

Straighten up a survival data frame
coxreg

Cox regression
geome.fit

Constant intensity discrete time proportional hazards
hazards

Get baseline hazards atoms from fits from
aftreg.fit

Parametric proportional hazards regression
perstat

Period statistics
coxreg2

Cox regression
age.window

Age cut of survival data
cal.window

Calendar time cut of survival data
phfunc

Loglihood function of a proportional hazards regression
plot.logrank

Plots of hazdata objects.
mort

Male mortality in ages 40-60, nineteenth century
logrye

Rye prices, Scania, southern Sweden, 1801-1894.
logrank

The Log-rank test
plot.tpchreg

Plots output from a tpchreg regression
oe

Create an oe object
oldmort

Old age mortality, Sundsvall, Sweden, 1860-1880.
pchreg

Piecewise Constant Proportional Hazards Regression
import_Surv

Surv function imported from survival
plot.phreg

Plots output from a phreg regression
plot.weibreg

Plots output from a Weibull regression
fert

Marital fertility nineteenth century
scania

Old age mortality, Scania, southern Sweden, 1813-1894.
ltx

LaTeX printing of regression results.
ltx2

LaTeX alternative printing of regression results.
frail.fit

Frailty experiment
summary.aftreg

Prints aftreg objects
male.mortality

Male mortality in ages 40-60, nineteenth century
phreg

Parametric Proportional Hazards Regression
import_strata

strata function imported from survival
make.communal

Put communals in "fixed" data frame
print.tpchreg

Prints tpchreg objects
print.coxreg

Prints coxreg objects
plot.aftreg

Plots output from an AFT regression
piecewise

Piecewise hazards
makeham

The Gompertz-Makeham Distribution
mlreg

ML proportional hazards regression
phreg.fit

Parametric proportional hazards regression
plot.coxreg

Plot method for coxreg objects
toTpch

Transform survival data to tabular form
plot.hazdata

Plots of hazdata objects.
plotHaz

Graphical comparing of cumulative hazards
tpchreg

Proportional hazards regression with piecewise constant hazards and tabular data.
print.summary.phreg

Prints summary.phreg objects
print.logrank

Prints logrank objects
print.phreg

Prints phreg objects
print.aftreg

Prints aftreg objects
print.summary.tpchreg

Prints summary.tpchreg objects
toDate

Convert time in years since "0000-01-01" to a date.
toTime

Calculate duration in years from "0000-01-01" to a given date
print.summary.aftreg

Prints summary.aftreg objects
print.summary.coxreg

Prints summary.coxreg objects
print.weibreg

Prints weibreg objects
weibreg

Weibull Regression
print.risksets

Prints a summary of the content of a set of risk sets.
summary.coxreg

A summary of coxreg objects.
swedeaths

Swedish death data, 1969-2020.
weibreg.fit

Weibull regression
regtable

Retrieves regression tables
table.events

Calculating failure times, risk set sizes and No. of events in each risk set
toBinary

Transforms a "survival" data frame into a data frame suitable for binary (logistic) regression
swepop

Swedish population data, 1969-2020.
summary.phreg

A summary of phreg objects.
wfunk

Loglihood function of a Weibull regression
risksets

Finds the compositions and sizes of risk sets
summary.tpchreg

Summary for tpchreg objects
summary.weibreg

Prints a weibreg object
Gompertz

The Gompertz Distribution
SurvSplit

Split a survival object at specified durations.
EV

The EV Distribution
Weibull

The (Cumulative) Hazard Function of a Weibull Distribution