Skip to content
Snippets Groups Projects
Commit 2fd99cb0 authored by Vincent  LAVILLE's avatar Vincent LAVILLE
Browse files

Change tol param in ginv

parent c8dde0f0
No related branches found
No related tags found
No related merge requests found
......@@ -163,7 +163,7 @@ calculateVarExp <- function(std_bG, std_bI, matcor, varY, N, type) {
stop("type must be in c(\"G\", \"I\", \"J\")", call. = FALSE)
}
q <- qr(matcor)$rank
inv <- ginv(matcor, tol = 0.1)
inv <- ginv(matcor, tol = 0.0001)
return((N * (crossprod(t(crossprod(std_bG, inv)), std_bG) +
crossprod(t(crossprod(std_bI, inv)), std_bI)) -
q) / ((N - q) * varY))
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment