GTDL: Distribuição GTDL

Description Usage Arguments Details Author(s) References Examples

Description

Função de risco, função de sobrevivência, densidade e MMV. .

Usage

1
2
3
4
5
6
7
8
9
hGTDL(t, theta)

sGTDL(t, theta)

dGTDL(t, theta, log = FALSE)

maxGTDL(theta, t)

maxGTDL2(theta, delta)

Arguments

t

variável aleatória não negativa que representa o tempo de falha.

theta

vetor com 3 entradas: lambda vetor de escalares, uma medida de efeito alpha e um vetor de parâmetros gama.

Details

Conjunto de quatro funções que recebem os parametros t e theta. Theta sendo um vetor com 3 parametros (lambda, alpha e gama). Na função maxGTDL o parametro theta recebe uma lista.

Author(s)

Jalmar M. F. Carrasco

Filipe O. Silva silva.filipe@ufba.br

References

MILANI, Eder Angelo. Modelo logístico generalizado dependente do tempo com fragilidade. 2011.

Mackenzie, G. Regression Models for Survival Data: The Generalized Time-Dependent Logistic Family. Journal of the Royal Statistical Society. 1996.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
Exemplo-I

library(GTDL)
library(ggplot2)

t <- seq(0, 20, by = 0.01)
theta <- c(1.00, -0.05, -1.00)
y1 <- hGTDL(t, theta)
y2 <- sGTDL(t, theta)
y3 <- dGTDL(t, theta)

df <- data.frame(t, y1, y2, y3)

ggplot(df, aes(t)) + geom_line(aes(y = y1))
+ geom_line(aes(y = y2), linetype = 2)
+ geom_line(aes(y = y3), linetype = 3)
+ labs(title = "Generalized Logistic Model" ,y = "")

Exemplo-II

t <- seq(0, 20, by = 0.01)
theta1 <- c(1.00, 0.50, -1.00)
theta2 <- c(1.00, -0.50, 1.00)
theta3 <- c(1.00, -0.25, 1.00)
theta4 <- c(1.00, -0.06, -1.60)
theta5 <- c(1.00, 0.25, -1.00)

y1 <- hGTDL(t, theta1)
y2 <- hGTDL(t, theta2)
y3 <- hGTDL(t, theta3)
y4 <- hGTDL(t, theta4)
y5 <- hGTDL(t, theta5)

df <- data.frame(t, y1, y2, y3, y4, y5)

ggplot(df, aes(t)) + geom_line(aes(y = y1), linetype = 2)
+ geom_line(aes(y = y2), linetype = 3) + geom_line(aes(y = y3), linetype = 4)
+ geom_line(aes(y = y4), linetype = 5) + geom_line(aes(y = y5), linetype = 6)
+ labs(title = "Hazard plots", y = "")

Exemplo-III

library(survival)
maxGTDL(theta = list(lambda=1,alpha=1,gama=-1), t = log(lung$time))

Exemplo-IV


t <- seadecovid2$TEMPO
c <- seadecovid2$EVOLUCAO
delta <- list(t, c)
theta <- c(1,1,-1)

maxGTDL2(theta = list(lambda=1,alpha=1,gama=-1), delta = delta)

filipesilv4/GTDL documentation built on Dec. 20, 2021, 8:41 a.m.