LVMMCOR-package: A Latent Variable Model for Mixed Continuous and Ordinal...

Description Details Author(s) References Examples

Description

A model for mixed ordinal and continuous responses is presented where the heteroscedasticity of the variance of the continuous response is also modeled.

Details

Package: LVMMCOR
Type: Package
Version: 1.0
Date: 2013-05-31
License: GPL (>=2)

Author(s)

Bahrami Samani and Nourallah Tazikeh Miyandarreh

Maintainer: Bahrami Samani <ehsan_bahrami_samani@yahoo.com>

References

Bahrami Samani, E., Ganjali, M. and Khodaddadi, A. (2008). A Latent Variable Model for Mixed Continuous and Ordinal Responses. Journal of Statistical Theory and Applications. 7(3):337-349.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
data("Bahrami")
gender<-Bahrami$ GENDER
age<-Bahrami$AGE
duration <-Bahrami$ DURATION
y<-Bahrami$ STEATOS
z<-Bahrami$  BMI
sbp<-Bahrami$ SBP
X=cbind(gender,age,duration ,sbp)
P<-lm(z~X)[[1]]
names(P)<-paste("Con_",names(P),sep="")
Q<-polr(factor(y)~X)[[1]]
names(Q)<-paste("Ord_",names(Q),sep="")
W=c(cor(y,z),polr(factor(y)~X)[[2]],var(z))
names(W)=c("Corr","cut_point1","cut_point2","Variance of Continous Response")
ini=c(P,Q,W)
p=5;
q=4;
LVMMCOR(ini,X=X,y=y,z=z,p=p,q=q)

Example output

Loading required package: nlme
Loading required package: MASS
Warning message:
glm.fit: fitted probabilities numerically 0 or 1 occurred 
Warning message:
glm.fit: fitted probabilities numerically 0 or 1 occurred 
$call
LVMMCOR.default(ini = ini, X = X, y = y, z = z, p = p, q = q)

$`Continuos Response`
                  Parameter        S.E Confidence.Interval
Con_(Intercept) 23.89308890 6.63646283      (10.62,37.166)
Con_Xgender     -1.14389263 1.38261351      (-3.909,1.621)
Con_Xage         0.32996775 0.09360033       (0.143,0.517)
Con_Xduration   -0.45605872 0.11500008     (-0.686,-0.226)
Con_Xsbp        -0.06089439 0.04590319      (-0.153,0.031)

$`Variance Of Countinous Response`
                               Parameter       S.E Confidence.Interval
Variance of Continous Response 0.8556298 0.1825731        (0.49,1.221)

$`Ordinal Response`
                Parameter        S.E Confidence.Interval
Ord_Xgender   -0.75227989 0.79897500       (-2.35,0.846)
Ord_Xage       0.01173232 0.05305946      (-0.094,0.118)
Ord_Xduration -0.02561587 0.06140197      (-0.148,0.097)
Ord_Xsbp      -0.02907185 0.02548615       (-0.08,0.022)

$`Cut points`
           Parameter      S.E Confidence.Interval
cut point1 -6.081947 3.951918     (-13.986,1.822)
cut point2 -4.616182 3.782163     (-12.181,2.948)

$Correlation
     Parameter       S.E Confidence.Interval
Corr 0.4263786 0.2666938       (-0.107,0.96)

$Hessian
               [,1]          [,2]          [,3]          [,4]          [,5]
 [1,]  3.075454e+00    2.28059606    176.178036    28.3294208    447.520361
 [2,]  2.280596e+00    2.28029227    131.215614    20.6718466    332.153261
 [3,]  1.761780e+02  131.21561356  10316.604672  1724.0582859  25786.089135
 [4,]  2.832942e+01   20.67184658   1724.058286   393.4184023   4179.811384
 [5,]  4.475204e+02  332.15326109  25786.089135  4179.8113842  65759.705856
 [6,] -1.619944e+00   -1.61995311    -94.092571   -15.3857811   -238.004981
 [7,] -1.169340e+02  -94.08245232  -6893.927405 -1143.6066358 -17259.634539
 [8,] -1.876919e+01  -15.38197302  -1143.585546  -257.1144850  -2795.195242
 [9,] -2.964893e+02 -238.00626485 -17259.596060 -2795.1625138 -43950.275676
[10,] -3.404725e-03   -0.07787036      2.149972     0.7703003      3.716665
[11,]  4.221072e-01    0.37578997     25.052516     5.1743075     66.292400
[12,]  1.596938e+00    1.24420600     91.881621    13.5952824    230.198442
[13,] -1.794939e-01   -0.08176654    -10.864763    -1.7638556    -26.758660
              [,6]         [,7]         [,8]         [,9]         [,10]
 [1,]   -1.6199437   -116.93399   -18.769187   -296.48934  -0.003404725
 [2,]   -1.6199531    -94.08245   -15.381973   -238.00626  -0.077870357
 [3,]  -94.0925714  -6893.92740 -1143.585546 -17259.59606   2.149971770
 [4,]  -15.3857811  -1143.60664  -257.114485  -2795.16251   0.770300328
 [5,] -238.0049808 -17259.63454 -2795.195242 -43950.27568   3.716665126
 [6,]    8.9391204    519.23566    84.909517   1313.37748   0.430736263
 [7,]  519.2356566  38041.92350  6310.347510  95241.93793 -11.853289071
 [8,]   84.9095168   6310.34751  1418.670272  15424.66922  -4.240237005
 [9,] 1313.3774754  95241.93793 15424.669215 242527.86466 -20.447324803
[10,]    0.4307363    -11.85329    -4.240237    -20.44732  16.051001134
[11,]   -2.0735151   -138.24173   -28.551063   -365.81375  -1.208731618
[12,]   -6.8657460   -507.02261   -75.020589  -1270.28585   1.189283446
[13,]    0.4524706     59.85889     9.733948    147.54286  -5.216934611
             [,11]         [,12]        [,13]
 [1,]    0.4221072     1.5969385  -0.17949391
 [2,]    0.3757900     1.2442060  -0.08176654
 [3,]   25.0525159    91.8816213 -10.86476258
 [4,]    5.1743075    13.5952824  -1.76385556
 [5,]   66.2923996   230.1984416 -26.75865989
 [6,]   -2.0735151    -6.8657460   0.45247059
 [7,] -138.2417346  -507.0226143  59.85889383
 [8,]  -28.5510628   -75.0205885   9.73394799
 [9,] -365.8137535 -1270.2858548 147.54286004
[10,]   -1.2087316     1.1892834  -5.21693461
[11,]    3.5687236    -1.2395056  -0.42885214
[12,]   -1.2395056    10.0517051  -0.55923541
[13,]   -0.4288521    -0.5592354  32.00406288

$convergence
[1] 0

attr(,"class")
[1] "LVMMCOR"

LVMMCOR documentation built on May 29, 2017, 7:05 p.m.