Description Usage Arguments Details Author(s) References Examples
Função de risco, função de sobrevivência, densidade e MMV. .
1 2 3 4 5 6 7 8 9 |
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. |
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.
Jalmar M. F. Carrasco
Filipe O. Silva silva.filipe@ufba.br
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.
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)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.