Skip to content

Commit 8854187

Browse files
committed
recommended exactLRT for boundary space sigma
1 parent d9c9f86 commit 8854187

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

Lecture-6-BroadSenseHeritability.ipynb

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -598,8 +598,11 @@
598598
"\n",
599599
" ourEstimate <- r.squared.merMod(lmer.alt);\n",
600600
" results[nrow(results), \"H2\"] <- ourEstimate['Conditional'] - ourEstimate['Marginal'];\n",
601-
" results[nrow(results), \"pvalue\"] <- anova(lmer.alt, lm.null)[2, \"Pr(>Chisq)\"];\n",
602601
"\n",
602+
" ## note that the mixed model has to be specified first\n",
603+
" ## if sigma is on the boundary, this approach is conservative; consider exactLRT which estimates the p-value using simulations.\n",
604+
" ## source: https://bbolker.github.io/mixedmodels-misc/glmmFAQ.html\n",
605+
" results[nrow(results), \"pvalue\"] <- anova(lmer.alt, lm.null)[2, \"Pr(>Chisq)\"];\n",
603606
"}"
604607
]
605608
},
@@ -727,7 +730,7 @@
727730
}
728731
],
729732
"source": [
730-
"results"
733+
"results;"
731734
]
732735
},
733736
{

0 commit comments

Comments
 (0)