Title: | Adjust Longitudinal Regression Models Using Bayesian Methodology |
---|---|
Description: | Adjusts longitudinal regression models using Bayesian methodology for covariance structures of composite symmetry (SC), autoregressive ones of order 1 AR (1) and autoregressive moving average of order (1,1) ARMA (1,1). |
Authors: | Edwin Javier Castillo Carreño, Edilberto Cepeda Cuervo |
Maintainer: | Edwin Javier Castillo Carreño <[email protected]> |
License: | GPL (>= 2) |
Version: | 0.1.0 |
Built: | 2024-11-29 08:49:16 UTC |
Source: | CRAN |
Build a block diagonal matrix with structure AR(1)
bloques(s, r, t, n)
bloques(s, r, t, n)
s |
Numerical value indicating global standard deviation of the matrix |
r |
Numerical value indicating correlation of individuals |
t |
Numerical value indicating number of times when observations are repeated |
n |
Numerical value indicating number of individuals |
A diagonal block matrix with structure AR(1)
Nuñez A. and Zimmerman D. 2001. Modelación de datos longitudinales con estructuras de covarianza no estacionarias: Modelo de coeficientes aleatorios frente a modelos alternativos. Questio. 2001. 25.
bloques(2,.5,10,2)
bloques(2,.5,10,2)
Build a block diagonal matrix with structure ARMA(1,1)
bloques2(s, r, g, t, n)
bloques2(s, r, g, t, n)
s |
Numerical value indicating global standard deviation of the matrix |
r |
Numerical value indicating the first parameter rho correlation of individuals |
g |
Numerical value indicating the second parameter phi correlation of individuals |
t |
Numerical value indicating number of times when observations are repeated |
n |
Numerical value indicating number of individuals |
A diagonal block matrix with structure ARMA(1,1)
Nuñez A. and Zimmerman D. 2001. Modelación de datos longitudinales con estructuras de covarianza no estacionarias: Modelo de coeficientes aleatorios frente a modelos alternativos. Questio. 2001. 25.
bloques2(2,.5,.8,10,2)
bloques2(2,.5,.8,10,2)
Build a block diagonal matrix with compound symmetry structure
bloques3(s, r, t, n)
bloques3(s, r, t, n)
s |
Numerical value indicating global standard deviation of the matrix |
r |
Numerical value indicating correlation of individuals |
t |
Numerical value indicating number of times when observations are repeated |
n |
Numerical value indicating number of individuals |
A diagonal block matrix with compound symmetry structure
Nuñez A. and Zimmerman D. 2001. Modelación de datos longitudinales con estructuras de covarianza no estacionarias: Modelo de coeficientes aleatorios frente a modelos alternativos. Questio. 2001. 25.
bloques3(2,.5,10,2)
bloques3(2,.5,10,2)
It reports the distance in millimeters from the center of the pituitary to the pteromaxillary fissure. The subjects were 16 children and 11 girls. Data were taken every two years from 8 years and ended at age 14.
Dental
Dental
A data Frame with 98 rows and 5 variables:
1 for girls, 0 for boy
Number of the individual
Distance from the center of the pituitary gland to the pterygomaxillary fissure
Child's age at which measurement was taken
Gender of the child
https://faculty.biostat.ucla.edu/robweiss/filedepot_download/87/524
Run Bayesian estimation of a balanced longitudinal model with AR(1) structure
mhar1(Data, Matriz, individuos, tiempos, betai, rhoi, beta1i, beta2i, iteraciones, burn)
mhar1(Data, Matriz, individuos, tiempos, betai, rhoi, beta1i, beta2i, iteraciones, burn)
Data |
A vector with the observations of the response variable |
Matriz |
The model design matrix |
individuos |
A numerical value indicating the number of individuals in the study |
tiempos |
A numerical value indicating the number of times observations were repeated |
betai |
A vector with the initial values of the vector of regressors |
rhoi |
A numerical value with the initial value of the correlation |
beta1i |
A numerical value with the shape parameter of a beta apriori distribution of rho |
beta2i |
A numerical value with the scaling parameter of a beta apriori distribution of rho |
iteraciones |
A numerical value with the number of iterations that will be applied the algorithm MCMC |
burn |
Number of iterations that are discarded from the chain |
A dataframe with the mean, median and standard deviation of each parameter, A graph with the histograms and chains for the parameters that make up the variance matrix, as well as the selection criteria AIC, BIC and DIC
Gamerman, D. 1997. Sampling from the posterior distribution in generalized linear mixed models. Statistics and Computing, 7, 57-68
Cepeda, C and Gamerman, D. 2004. Bayesian modeling of joint regressions for the mean and covariance matrix. Biometrical journal, 46, 430-440.
Cepeda, C and Nuñez, A. 2007. Bayesian joint modelling of the mean and covariance structures for normal longitudinal data. SORT. 31, 181-200.
Nuñez A. and Zimmerman D. 2001. Modelación de datos longitudinales con estructuras de covarianza no estacionarias: Modelo de coeficientes aleatorios frente a modelos alternativos. Questio. 2001. 25.
attach(Dental) Y=as.vector(distance) X=as.matrix(cbind(1,age)) mhar1(Y,X,27,4,c(1,1),0.5,1,1,500,50)
attach(Dental) Y=as.vector(distance) X=as.matrix(cbind(1,age)) mhar1(Y,X,27,4,c(1,1),0.5,1,1,500,50)
Run Bayesian estimation of a balanced longitudinal model with ARMA(1) structure
mharma11(Data, Matriz, individuos, tiempos, betai, rhoi, gammai, beta1i, beta2i, beta1j, beta2j, iteraciones, burn)
mharma11(Data, Matriz, individuos, tiempos, betai, rhoi, gammai, beta1i, beta2i, beta1j, beta2j, iteraciones, burn)
Data |
A vector with the observations of the response variable |
Matriz |
The model design matrix |
individuos |
A numerical value indicating the number of individuals in the study |
tiempos |
A numerical value indicating the number of times observations were repeated |
betai |
A vector with the initial values of the vector of regressors |
rhoi |
A numerical value with the initial value of the correlation for rho |
gammai |
A numerical value with the initial value of the correlation for phi |
beta1i |
A numerical value with the shape parameter of a beta apriori distribution of rho |
beta2i |
A numerical value with the scaling parameter of a beta apriori distribution of rho |
beta1j |
A numerical value with the shape parameter of a beta apriori distribution of phi |
beta2j |
A numerical value with the scaling parameter of a beta apriori distribution of phi |
iteraciones |
A numerical value with the number of iterations that will be applied the algorithm MCMC |
burn |
Number of iterations that are discarded from the chain |
A dataframe with the mean, median and standard deviation of each parameter, A graph with the histograms and chains for the parameters that make up the variance matrix, as well as the selection criteria AIC, BIC and DIC
Gamerman, D. 1997. Sampling from the posterior distribution in generalized linear mixed models. Statistics and Computing, 7, 57-68
Cepeda, C and Gamerman, D. 2004. Bayesian modeling of joint regressions for the mean and covariance matrix. Biometrical journal, 46, 430-440.
Cepeda, C and Nuñez, A. 2007. Bayesian joint modelling of the mean and covariance structures for normal longitudinal data. SORT. 31, 181-200.
Nuñez A. and Zimmerman D. 2001. Modelación de datos longitudinales con estructuras de covarianza no estacionarias: Modelo de coeficientes aleatorios frente a modelos alternativos. Questio. 2001. 25.
attach(Dental) Y=as.vector(distance) X=as.matrix(cbind(1,age)) mharma11(Y,X,27,4,c(1,1),0.5,0.5,1,1,1,1,500,50)
attach(Dental) Y=as.vector(distance) X=as.matrix(cbind(1,age)) mharma11(Y,X,27,4,c(1,1),0.5,0.5,1,1,1,1,500,50)
Run Bayesian estimation of a balanced longitudinal model with compound symmetry structure
mhsc(Data, Matriz, individuos, tiempos, betai, rhoi, beta1i, beta2i, iteraciones, burn)
mhsc(Data, Matriz, individuos, tiempos, betai, rhoi, beta1i, beta2i, iteraciones, burn)
Data |
A vector with the observations of the response variable |
Matriz |
The model design matrix |
individuos |
A numerical value indicating the number of individuals in the study |
tiempos |
A numerical value indicating the number of times observations were repeated |
betai |
A vector with the initial values of the vector of regressors |
rhoi |
A numerical value with the initial value of the correlation |
beta1i |
A numerical value with the shape parameter of a beta apriori distribution of rho |
beta2i |
A numerical value with the scaling parameter of a beta apriori distribution of rho |
iteraciones |
numerical value with the number of iterations that will be applied the algorithm MCMC |
burn |
Number of iterations that are discarded from the chain |
A dataframe with the mean, median and standard deviation of each parameter, A graph with the histograms and chains for the parameters that make up the variance matrix, as well as the selection criteria AIC, BIC and DIC
Gamerman, D. 1997. Sampling from the posterior distribution in generalized linear mixed models. Statistics and Computing, 7, 57-68
Cepeda, C and Gamerman, D. 2004. Bayesian modeling of joint regressions for the mean and covariance matrix. Biometrical journal, 46, 430-440.
Cepeda, C and Nuñez, A. 2007. Bayesian joint modelling of the mean and covariance structures for normal longitudinal data. SORT. 31, 181-200.
Nuñez A. and Zimmerman D. 2001. Modelación de datos longitudinales con estructuras de covarianza no estacionarias: Modelo de coeficientes aleatorios frente a modelos alternativos. Questio. 2001. 25.
attach(Dental) Y=as.vector(distance) X=as.matrix(cbind(1,age)) mhsc(Y,X,27,4,c(1,1),0.5,1,1,500,50)
attach(Dental) Y=as.vector(distance) X=as.matrix(cbind(1,age)) mhsc(Y,X,27,4,c(1,1),0.5,1,1,500,50)