Freedom for replicate bears [🇷 for BE/BA]
Replicate berlin buddy bears
Dear all, especially the Ruses among you,
(ok, the category could also has been Regulatives/guidelines)
continuing my deeper look into R exemplified by the source code of bear I noticed the following:
The key statement in bear for evaluating replicate BE studies (astonishing enough claimed as only 2-sequence designs allowed?) is
model <- lme(y~seq+prd+drug, random=~1|subj, data=blabla, method="REML")
with y the PK parameter under evaluation (raw or log-transformed).
This is the equivalent of SAS Proc MIXED code:
Proc MIXED data=BlaBla ;
class subj drug prd seq;
model y=drug prd seq /ddfm=BETWITHIN;
random subj;
estimate 'T-R' tmt -1 1 /cl alpha=0.1;
run;
The used model assumes equal within/between variabilities for Test and Reference and also no subject-by-treatment-interaction, if I'm right.
This is very stringent and consequent, if we talk about ABE.
But in real world there are regulators out there!
And some of them do not like consequent scientific assumptions / models.
Thus it happens that the FDA model for evaluating ABE within replicate designs (discussed occasionally here in the forum, SEARCH!!!) must have different within/between variabilities for Test and Reference and also subject-by-treatment-interaction included in the model.
After reading again tons of Websites (seems nobody evaluates x-over studies with R) I came up with the following attempt in R:
model2 <- lme(y~ drug + prd + seq,
# this random statement fits a symmetric positive definite covariance matrix,
# identical to UN in SAS???
random= ~ tmt-1|subj,
#different within variabilities
weights=varIdent(form = ~ 1 | drug),
data=BlaBla, method="REML")
This code gives for the bear built in dataset the same covariance parameters as the SAS code from the FDA statistical guidance except the fact that SAS Proc MIXED uses variances and the lme() code uses standard deviations.
--- snip ----
SAS:
The Mixed Procedure
Estimated G Matrix
Row Effect tmt subject Col1 Col2
1 tmt R 1 0.02220 0.002729
2 tmt T 1 0.002729 0.01492
Covariance Parameter Estimates
Standard Z
Cov Parm Subject Group Estimate Error Value Pr Z
UN(1,1) subject 0.02220 0.009077 2.45 0.0072
UN(2,1) subject 0.002729 0.005318 0.51 0.6079
UN(2,2) subject 0.01492 0.006095 2.45 0.0072
Residual subject tmt R 0.000058 0.000023 2.50 0.0061
Residual subject tmt T 0.000011 4.762E-6 2.37 0.0090
R (have changed drug to tmt, prd to period, subj to subject)
cat("G matrixn")
getVarCov(model2)
G matrix
Random effects variance covariance matrix
tmtR tmtT
tmtR 0.0222050 0.0027286
tmtT 0.0027286 0.0149240
Standard Deviations: 0.14901 0.12216
print(model2)
Linear mixed-effects model fit by REML
Data: PKparms
Log-restricted-likelihood: 98.1282
Fixed: y ~ tmt + period + sequence
(Intercept) tmtT period2 period3 period4 sequenceTRRT
7.35627371 0.06373952 -0.06170010 -0.05964129 0.00348174 0.00266416
Random effects:
Formula: ~tmt - 1 | subject
Structure: General positive-definite, Log-Cholesky parametrization
StdDev Corr
tmtR 0.14901302 tmtR
tmtT 0.12216340 0.15
any body out there who knows how to get more decimals here?
Residual 0.00335726
Variance function:
Structure: Different standard deviations per stratum
Formula: ~1 | tmt
Parameter estimates:
T R
1.00000 2.27674
Number of Observations: 56
Number of Groups: 14
--- end snip ---
I was soooo happy: An old SAS dog, nothing learned else, has become a Ruser!
But then it came to the freedom to some degree:
--- snip ---
SAS: now with the DDFM=SATTERTHWAITE (DDFM = denominator degree of freedom method)
Type 3 Tests of Fixed Effects
Num Den
Effect DF DF F Value Pr > F
Drug 1 12 1.79 0.2053
prd 3 14.3 2.59 0.0930
seq 1 12 0.00 0.9623
R:
anova(model2,type="marginal")[2:4,]
numDF denDF F-value p-value
tmt 1 38 1.793900 0.1884
period 3 38 2.593551 0.0667
sequence 1 12 0.002331 0.9623
--- end snip ---
Ok, I have learned (by reading again tons of websites) that R has no package with Satterthwaite denominator degrees of freedom in mixed models.
But all other available DDFM in Proc MIXED gave not a denDF=38 for the treatment effect. One gets always lower denDF in SAS and as a consequence of that wider 90% confidence intervals!
Thus my choice of software would be lme() and R because with that it is easier to make my sponsors happy .
But the question is: Are regulators evenly happy with that?
Whats going on here? Do I miss anything in the R approach?
Or is the denominator DF question also like type III SumOfSquares? (I have read some Websites indicating that).
BTW: Parallel Bears (crossing at infinity according to the geometric axioms) have also same variance . But this is another story.
—
Regards,
Detlew
Regards,
Detlew
Complete thread:
- Freedom for replicate bearsd_labes 2009-04-17 12:06 [🇷 for BE/BA]
- Freedom for replicate bears ElMaestro 2009-04-17 14:50
- Contain does not contain d_labes 2009-04-17 15:07
- Freedom for replicate bears ElMaestro 2009-04-18 03:45
- Freedom incompatible with baseball bats d_labes 2009-04-20 08:42
- Freedom for replicate bears yjlee168 2009-04-19 21:38
- Freedom to some degree d_labes 2009-04-20 08:30
- Freedom to some degree yjlee168 2009-04-21 14:03
- FDA loves replicate bears? d_labes 2009-04-21 16:11
- Cholesky factor ?! Helmut 2009-04-22 00:46
- Cholesky factor ?! d_labes 2009-04-22 11:20
- FDA loves replicate bears? yjlee168 2009-04-23 08:08
- FDA loves SAS code? d_labes 2009-04-23 09:48
- FDA loves SAS code? definitely. yjlee168 2009-04-23 10:46
- SAS? or R? or what? d_labes 2009-04-23 15:07
- SAS? or R? or what? Helmut 2009-04-23 15:25
- SAS? or R? or what? d_labes 2009-04-23 16:06
- SAS? or R? or what? Helmut 2009-04-23 16:30
- SAS? or R? or what? d_labes 2009-04-23 16:06
- SAS? YES; R? why not? as long as they are useful... yjlee168 2009-04-23 19:56
- New Forum-Category 'bear'? Helmut 2009-04-23 20:03
- New Forum-Category 'bear'? yjlee168 2009-04-23 20:19
- New Forum-Category 'R for BE/BA' Helmut 2009-04-23 20:37
- New Forum-Category 'R for BE/BA' yjlee168 2009-04-24 09:19
- New Forum-Category 'R for BE/BA' Helmut 2009-04-23 20:37
- New Forum-Category 'bear'? yjlee168 2009-04-23 20:19
- Replicated again d_labes 2009-04-24 08:27
- Replicated again yjlee168 2009-04-24 09:26
- New Forum-Category 'bear'? Helmut 2009-04-23 20:03
- SAS? or R? or what? Helmut 2009-04-23 15:25
- SAS? or R? or what? d_labes 2009-04-23 15:07
- FDA loves SAS code? definitely. yjlee168 2009-04-23 10:46
- FDA loves SAS code? d_labes 2009-04-23 09:48
- Cholesky factor ?! Helmut 2009-04-22 00:46
- FDA loves replicate bears? d_labes 2009-04-21 16:11
- Freedom to some degree yjlee168 2009-04-21 14:03
- Freedom to some degree d_labes 2009-04-20 08:30
- getting decimals ElMaestro 2010-06-03 05:21
- getting decimals yjlee168 2010-06-03 08:37
- getting decimals ElMaestro 2010-06-04 01:59
- getting decimals yjlee168 2010-06-03 08:37
- Freedom for replicate bears ElMaestro 2011-01-27 21:50
- lmer vs. lme d_labes 2011-01-28 09:02
- lmer vs. lme ElMaestro 2011-01-28 09:42
- lmer vs. lme d_labes 2011-01-28 11:37
- V ElMaestro 2011-01-28 12:14
- V corrected d_labes 2011-01-28 14:12
- V corrected ElMaestro 2011-01-28 15:20
- Peculiar partial replicate d_labes 2011-01-28 16:10
- V corrected ElMaestro 2011-01-28 15:20
- V corrected d_labes 2011-01-28 14:12
- V ElMaestro 2011-01-28 12:14
- lmer vs. lme d_labes 2011-01-28 11:37
- lmer vs. lme ElMaestro 2011-01-28 09:42
- lmer vs. lme d_labes 2011-01-28 09:02
- Freedom for replicate bears ElMaestro 2009-04-17 14:50