[R] loglin output

Juan Carlos Correa Morales jccorrea at perseus.unalmed.edu.co
Mon Nov 19 18:16:57 CET 2001


Hi all R-users:

I am getting some differences from the loglin function in R and S-Plus. Is
there a bug in the R function? 

Juan C. Correa  

> parentesco<-array(c(27,12,23,7,394,142,421,94,18,13,24,4,48,25,55,
13,2,2,4,1,32,19,38,11,1,1,0,3,6,4,15,4),c(2,2,2,2,2))

Output from R 1.3.1

> temp<-loglin(parentesco,list(c(3,4),c(1,2)), param=T)
2 iterations: deviation 2.273737e-13 
> temp
$lrt
[1] 1126.472

$pearson
[1] 968.6632

$df
[1] 25

$margin
$margin[[1]]
[1] 1 2

$margin[[2]]
[1] 3 4


$param
$param$"(Intercept)"
[1] 2.927703

$param$"1.5"
           [,1]       [,2]
[1,]  0.5819121  0.5819121
[2,] -0.5819121 -0.5819121

$param$"2"
[1]  0.09264558 -0.09264558

$param$"3"
[1] -0.9171482  0.9171482

$param$"4"
[1]  0.5276034 -0.5276034

$param$"1.2.5"
, , 1

           [,1]       [,2]
[1,] -0.1396115  0.1396115
[2,]  0.1396115 -0.1396115

, , 2

           [,1]       [,2]
[1,] -0.1396115  0.1396115
[2,]  0.1396115 -0.1396115


$param$"3.4"
           [,1]       [,2]
[1,] -0.4286906  0.4286906
[2,]  0.4286906 -0.4286906

============================================================
Output from S-Plus 6

> temp<-loglin(parentesco,list(c(3,4),c(1,2)), param=T)
2 iterations: deviation 1.52588e-005 
> temp
$lrt:
[1] 1126.472

$pearson:
[1] 968.6632

$df:
[1] 25

$margin:
$margin[[1]]:
[1] 3 4

$margin[[2]]:
[1] 1 2



$param:
$constant:
[1] 2.927703

$"1":
[1]  0.5819121 -0.5819121

$"2":
[1]  0.09264556 -0.09264556

$"1 X 2":
           [,1]       [,2] 
[1,] -0.1396115  0.1396115
[2,]  0.1396115 -0.1396115

$"3":
[1] -0.9171482  0.9171482

$"4":
[1]  0.5276034 -0.5276034

$"3 X 4":
           [,1]       [,2] 
[1,] -0.4286905  0.4286905
[2,]  0.4286905 -0.4286905


> 



-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list