BookmarkSubscribeRSS Feed
☑ This topic is solved. Need further help from the community? Please sign in and ask a new question.
AnnaB
Calcite | Level 5

I am working on a large study of bovine coronavirus (BCoV) in dairies. I have sampled around 125 dairies around Europe, and I have taken samples from calves for virus isolation (5-20 calves per dairy = 1300 samples). I want to determine risk factors for a calf being positive for BCoV and have thus developed logistic models in genmod and glimmix.In this example, the predictive variable is if the cows are vaccinated against BCoV. I have previously worked with logistic GEE models in proc genmod, and now want to understand glimmix a bit better.

 

I have run univariate of all variables (100+ variables), and thereafter I ran a univariate with all models in genmod with repeated measures on farm.

 

title2 'NEONATAL calves- % virus+';
title3 'Genmod: GEE univariate analysis, marginal';
proc genmod data=neonatal_calf desc ;
class farm country BCoV_dam_vacc(ref='no') / param=ref;
model virus_fn = BCoV_dam_vacc
/alpha = 0.05 link=logit dist=bin;
repeated subject = farm;
run;

 

When I run this conditional model in glimmix I get similar very non-significant results:

Title3 'NEONATAL calves- % virus+';
title4 'Glimmix - population average, marginal';
proc glimmix data=neonatal_calf ic=q or noitprint ;
nloptions maxiter = 100;
class farm country BCoV_dam_vacc(ref='no') ;
model virus_fn(descending) = BCoV_dam_vacc
/distribution = binary link = logit alpha=0.05;
random intercept / subject=farm;
covtest /wald;
run;

 

However, when I run this marginal model I get the outcomes to be much more significant.

random _residual_ / subject=farm SOLUTION CL type=vc;

 

 

I am a bit confused about the most appropriate model, and how to code the random effect of farm.

When i look at the distribution of BCoV positive calves (events) in the farms, there are 58% of the farms where I do not find any positive calves.

 

Then i tried another model approach with looking at the proportion of calves positive in a farm:

proc glimmix data=neonatal_calf;
class farm country BCoV_dam_vacc(ref='no');
model NCBCoV/NCtotal =BCoV_dam_vacc / solution;
random farm; run;

Then the model specifies:

Number of Observations Read 1338
Number of Observations Used 1138
Number of Events 4327
Number of Trials 16974

Why do I get some many events and trials from the 1338 calves in the study?

 

I am grateful for any advice and tips to move this analysis forward.

 

Kind regards, Cat.

 

1 ACCEPTED SOLUTION
2 REPLIES 2
SteveDenham
Jade | Level 19

For the first question, I have a hunch that it might be due to a change in the denominator degrees of freedom as you have moved farm from a G side effect to an R side effect. Also, consider that the results for the F value do change when you go from an all G side parameterization to a G and R parameterization. Walt Stroup's text covers what could be happening with your situation.

 

The second part about why the number of events and trials differ so greatly between the two approaches is harder to answer. I am not sure how your data are structured, but I think that may be part of what is happening. For things like this, I have always trusted what @jiltao has said, and @Mike_N  has made some great comments recently.

 

SteveDenham

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 386 views
  • 0 likes
  • 3 in conversation