Learn R Programming

TBSSurvival (version 1.0)

tbs: The TBS Time Failure Distribution

Description

Density, distribution function, quantile function, random generation and hazard function for the TBS distribution.

Usage

dtbs(time,lambda=1,xi=1,beta=1,x=NULL,dist="norm")
 ptbs(time,lambda=1,xi=1,beta=1,x=NULL,dist="norm")
 qtbs(p,lambda=1,xi=1,beta=1,x=NULL,dist="norm")
 rtbs(n,lambda=1,xi=1,beta=1,x=NULL,dist="norm")
 htbs(time,lambda=1,xi=1,beta=1,x=NULL,dist="norm")

Arguments

time
vector of quantiles.
p
vector of probabilities.
n
number of observations.
lambda
parameter of TBS.
xi
parameter of the error distribution.
beta
parameter of the linear regressor.
x
vector/matrix of co-variables, x=NULL if there are not co-variables.
dist
Distribution of error, dist = "norm", "t", "doubexp", "cauchy" or "logistic".

Value

  • `dtbs' gives the density, `ptbs' gives the distribution function, `qtbs' gives the quantile function, `rtbs' generates random deviates, `htbs' gives the hazard function.

Details

The density, distribution function, quantile function, random generation and hazard function for the failure time of a TBS Model. The distribution of error can be chosen from Normal, t-Student, Cauchy, Logistic and Doub-Exponential (Laplace).

Examples

Run this code
ptbs(1,lambda=2,xi=1,beta=1,dist="norm")

Run the code above in your browser using DataLab