z**********i 发帖数: 12276 | 1 因为,到sas community去问了,只好用我蹩脚的英语,也懒得再变成中文,就直接贴
到这了,另外,也看看大家是否可以看懂。
We met with a wired issue when we use proc genmod.
The code is straightforward, we have repeated measures data for hospitals,
so we put hsp_ID as subject in the repeated statement. Totnum is total
numerator for each hospital by quarter and totdenom is total denominator for
each hospital by quarter. This step is variable seletion. By throwing one
candidate variable at a time and checking the p value, if p value is
greater than 0.1, then we remove it and less than 0.1 we will keep it in the
model.
Before we run this code, we sort the data by hospital ID. But, when two
person work on the same code, they have different output. Then, we figured
it out, one person sort the data by hospital ID and quarter, and another
person sort the data by hospital ID and status (a variable in the dataset).
proc genmod data=dsn;
class hsp_ID &indvars.;
model totnum/totdenom=&indvars./dist=binomial link=logit;
repeated subject=hsp_ID/type=AR corrw;
run;
Sometimes, both of their p value are greater than 0.1 or less than 0.1, but
sometimes, one is greater than 0.1 and another is less than. So, the same
dataset and same coding give us different output if we sort the data
differently.
Grateful for any thoughts or suggestions! | A****1 发帖数: 33 | 2 I guess the observations are not independent.
Correlation among the observations will distort the significance test.
for
one
the
【在 z**********i 的大作中提到】 : 因为,到sas community去问了,只好用我蹩脚的英语,也懒得再变成中文,就直接贴 : 到这了,另外,也看看大家是否可以看懂。 : We met with a wired issue when we use proc genmod. : The code is straightforward, we have repeated measures data for hospitals, : so we put hsp_ID as subject in the repeated statement. Totnum is total : numerator for each hospital by quarter and totdenom is total denominator for : each hospital by quarter. This step is variable seletion. By throwing one : candidate variable at a time and checking the p value, if p value is : greater than 0.1, then we remove it and less than 0.1 we will keep it in the : model.
| z**********i 发帖数: 12276 | 3 https://communities.sas.com/thread/41127
我没有搞懂为什么,但这位大师给了些指点。
多谢你的回复!
【在 A****1 的大作中提到】 : I guess the observations are not independent. : Correlation among the observations will distort the significance test. : : for : one : the
| o****o 发帖数: 8077 | 4 I guess this is because you use AR(1) structure and naturally the ordering
within Hospital ID matters, and the difference will be reflected in your
working correlation matrix, and with different working correlation matrix,
the final covariance matrix will be different which of course influences the
p-value you can get.
just my $0.02, correct me if I am wrong. Why do u use AR(1) specification?
Is there any ordering of the observations within Hospital ID you have to
follow or want to model?
for
one
the
【在 z**********i 的大作中提到】 : 因为,到sas community去问了,只好用我蹩脚的英语,也懒得再变成中文,就直接贴 : 到这了,另外,也看看大家是否可以看懂。 : We met with a wired issue when we use proc genmod. : The code is straightforward, we have repeated measures data for hospitals, : so we put hsp_ID as subject in the repeated statement. Totnum is total : numerator for each hospital by quarter and totdenom is total denominator for : each hospital by quarter. This step is variable seletion. By throwing one : candidate variable at a time and checking the p value, if p value is : greater than 0.1, then we remove it and less than 0.1 we will keep it in the : model.
| z**********i 发帖数: 12276 | 5 我一拍脑门想出来的。没有必要用ar1.呵呵。
多谢提醒。
the
【在 o****o 的大作中提到】 : I guess this is because you use AR(1) structure and naturally the ordering : within Hospital ID matters, and the difference will be reflected in your : working correlation matrix, and with different working correlation matrix, : the final covariance matrix will be different which of course influences the : p-value you can get. : just my $0.02, correct me if I am wrong. Why do u use AR(1) specification? : Is there any ordering of the observations within Hospital ID you have to : follow or want to model? : : for
|
|