Diagnostics: R [Study Assessment]
Dear Helmut.
DF, p-values, CIs not reported in lmer for the reasons stated there.
For more decimal places:
Some reference for lmer can be found in this PDF.
For DFs, p-values, ...: library lmerTest can be used, see this PDF (page 2 - description, details, references to SAS).
Results:
I think there is a little bug in df visualization - rounded on 3 decimal places, visible on 5 (actually I have not the latest version of R).
For calculation of 90% CIs: (below is only example for Intercept lower and upper limit)
Best regards,
zizou
❝ Estimates and their SEs are exactly the same. CIs are not (due to different DFs?).
# equivalent of your code:
library(lme4)
Subj <- c(1, 2, 4, 5, 6, 4, 5, 6, 7, 8, 9, 7, 8, 9)
Dose <- c(25, 25, 50, 50, 50, 250, 250, 250, 75, 75, 75, 250, 250, 250)
AUC <- c(326.40, 437.82, 557.47, 764.85, 943.59, 2040.84, 2989.29,
4107.58, 1562.42, 982.02, 1359.68, 3848.86, 4333.10, 3685.55)
Cmax <- c(64.82, 67.35, 104.15, 143.12, 243.63, 451.44, 393.45,
796.57, 145.13, 166.77, 296.90, 313.00, 387.00, 843.00)
resp <- data.frame(Subj, Dose, Cmax, AUC)
muddle <- lmer(log(Cmax) ~ log(Dose) + (1|Subj), data=resp)
summary(muddle)
DF, p-values, CIs not reported in lmer for the reasons stated there.
For more decimal places:
print(muddle, digits=7, ranef.comp=c("Var","Std.Dev."))
# REML criterion at convergence: 6.2435 (same as in SPSS 6.243548)
# note: -2 (Restricted) Log Likelihood from R lme: (-2)*(-3.121774) = 6.243548
Some reference for lmer can be found in this PDF.
For DFs, p-values, ...: library lmerTest can be used, see this PDF (page 2 - description, details, references to SAS).
library(lmerTest) # Library includes modification of function lmer (if I am not mistaken).
muddle <- lmer(log(Cmax) ~ log(Dose) + (1|Subj), data=resp)
summary(muddle)
Results:
Linear mixed model fit by REML t-tests use Satterthwaite approximations to
degrees of freedom [lmerMod]
Formula: log(Cmax) ~ log(Dose) + (1 | Subj)
Data: resp
REML criterion at convergence: 6.2
Scaled residuals:
Min 1Q Median 3Q Max
-1.07548 -0.35579 -0.03301 0.45089 0.91854
Random effects:
Groups Name Variance Std.Dev.
Subj (Intercept) 0.11205 0.3347
Residual 0.01456 0.1207
Number of obs: 14, groups: Subj, 8
Fixed effects:
Estimate Std. Error df t value Pr(>|t|)
(Intercept) 1.94139 0.24314 9.19600 7.985 1.98e-05 ***
log(Dose) 0.76174 0.04728 5.89600 16.111 4.24e-06 ***
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Correlation of Fixed Effects:
(Intr)
log(Dose) -0.863
I think there is a little bug in df visualization - rounded on 3 decimal places, visible on 5 (actually I have not the latest version of R).
summary(muddle)$coefficients["(Intercept)","df"]
# [1] 9.195607
For calculation of 90% CIs: (below is only example for Intercept lower and upper limit)
alpha=0.05
summary(muddle)$coefficients["(Intercept)","Estimate"] - qt(1-alpha,summary(muddle)$coefficients["(Intercept)","df"]) * summary(muddle)$coefficients["(Intercept)","Std. Error"]
summary(muddle)$coefficients["(Intercept)","Estimate"] + qt(1-alpha,summary(muddle)$coefficients["(Intercept)","df"]) * summary(muddle)$coefficients["(Intercept)","Std. Error"]
Best regards,
zizou
Complete thread:
- Dose Proportionality and Variance AngusMcLean 2016-05-11 16:55 [Study Assessment]
- More information, please Helmut 2016-05-12 14:34
- More information, please AngusMcLean 2016-05-13 16:40
- Setup in Phoenix/WinNonlin Helmut 2016-05-14 02:26
- Setup in Phoenix/WinNonlin AngusMcLean 2016-05-14 18:54
- Setup in Phoenix/WinNonlin Helmut 2016-05-15 14:47
- Setup in Phoenix/WinNonlin AngusMcLean 2016-05-15 15:17
- Phoenix 64 Warning Helmut 2016-05-15 15:56
- Phoenix 64 Warning AngusMcLean 2016-05-15 20:11
- OT: imperial vs. metric units Helmut 2016-05-16 16:26
- Phoenix 64 Warning AngusMcLean 2016-05-15 20:11
- Setup in Phoenix/WinNonlin ElMaestro 2016-05-15 20:54
- Setup in Phoenix/WinNonlin AngusMcLean 2016-05-15 22:30
- Phoenix 64 Warning Helmut 2016-05-15 15:56
- Setup in Phoenix/WinNonlin AngusMcLean 2016-05-15 15:17
- Setup in Phoenix/WinNonlin Helmut 2016-05-15 14:47
- Setup in Phoenix/WinNonlin AngusMcLean 2016-05-16 21:00
- NCSS vs. PHX/WNL vs. SAS Helmut 2016-05-17 01:50
- NCSS vs. PHX/WNL vs. SAS - Validation? mittyri 2016-05-18 08:23
- Diagnostics ElMaestro 2016-05-18 09:20
- Diagnostics: R and Phoenix Helmut 2016-05-18 15:14
- Diagnostics: Rzizou 2016-05-22 19:07
- Diagnostics: R Helmut 2016-05-23 01:22
- SASian potpourri d_labes 2016-05-24 12:02
- Compilation Helmut 2016-05-24 14:27
- REML or not d_labes 2016-05-24 16:33
- complete or not Helmut 2016-05-24 16:57
- Compilation AngusMcLean 2016-05-26 16:46
- doubts about NCSS Helmut 2016-05-26 19:13
- Doubts about NCSS zizou 2016-05-26 23:38
- doubts about NCSS Helmut 2016-05-26 19:13
- Compilation AngusMcLean 2016-05-28 00:51
- Kenward-Roger? Helmut 2016-05-28 15:59
- 90% confidence interval for R_dnm Shuanghe 2019-01-04 17:45
- 90% confidence interval for R_dnm d_labes 2019-01-05 14:01
- Visualizing lmer and limits mittyri 2019-01-06 17:00
- Visualizing lmer and limits Shuanghe 2019-01-07 11:05
- Visualizing lmer and limits d_labes 2019-01-07 15:08
- Visualizing lmer and limits mittyri 2019-01-13 23:53
- 90% confidence interval for R_dnm Shuanghe 2019-01-07 10:53
- 90% confidence interval for R_dnm d_labes 2019-01-07 15:17
- 90% confidence interval for R_dnm Shuanghe 2019-01-07 17:11
- 90% confidence interval for R_dnm d_labes 2019-01-07 18:24
- offtop: greek letters and tables mittyri 2019-01-08 00:19
- OT: greek letters and symbols Helmut 2019-02-02 16:04
- 90% confidence interval for R_dnm Shuanghe 2019-01-07 17:11
- 90% confidence interval for R_dnm d_labes 2019-01-07 15:17
- Visualizing lmer and limits mittyri 2019-01-06 17:00
- 90% confidence interval for R_dnm d_labes 2019-01-05 14:01
- REML or not d_labes 2016-05-24 16:33
- Compilation Helmut 2016-05-24 14:27
- SASian potpourri d_labes 2016-05-24 12:02
- Diagnostics: R Helmut 2016-05-23 01:22
- Diagnostics: Rzizou 2016-05-22 19:07
- Diagnostics: R and Phoenix Helmut 2016-05-18 15:14
- Smith’s paper Helmut 2016-05-18 14:44
- Smith’s paper d_labes 2019-01-05 15:00
- Diagnostics ElMaestro 2016-05-18 09:20
- NCSS vs. PHX/WNL vs. SAS - Validation? mittyri 2016-05-18 08:23
- NCSS vs. PHX/WNL vs. SAS Helmut 2016-05-17 01:50
- Setup in Phoenix/WinNonlin AngusMcLean 2016-05-14 18:54
- Setup in Phoenix/WinNonlin Helmut 2016-05-14 02:26
- More information, please AngusMcLean 2016-05-13 16:40
- More information, please Helmut 2016-05-12 14:34