[Rd] miscomputation (PR#13594)
sarmad at um.ac.ir
sarmad at um.ac.ir
Sun Mar 15 20:35:11 CET 2009
Full_Name: Majid Sarmad
Version: 2.8.1
OS: Linux / Windows
Submission from: (NULL) (194.225.128.135)
With thanks to Alberto Viglione, in HW.tests function of homtest package, there
is the following line
V2 <- (sum(ni * ((ti - tauReg)^2 + (t3i - tau3Reg)^2))/sum(ni) )^0.5
which is a mistyping and leads to a miscomputation. It must be
V2 <- sum(ni * ((ti - tauReg)^2 + (t3i - tau3Reg)^2) ^0.5) /sum(ni)
as it is in help file of the function:
V2 = sum[i from 1 to k] ni {(t^(i) - t^R)^2 + (t3^(i) - t3^R)^2}^(1/2) / sum[i
from 1 to k] ni
Similarly, in
V2s[i] <- (sum(ni * ((ti.sim - tauReg.sim)^2 + (t3i.sim -
tau3Reg.sim)^2))/sum(ni))^0.5
More information about the R-devel
mailing list