BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
igforek
Quartz | Level 8

I am rather new to using SAS and EG, I have installed SAS 9.4 and EG 6.1 (both 64-bit) in my PC. I mostly use EG. I am able to run proc mixed in EG, but I cannot figure out how to run glimmix. Can anyone help me? Thank you in advance for your kind help.

Regards

1 ACCEPTED SOLUTION

Accepted Solutions
ChrisHemedinger
Community Manager

Are you trying to run it as a program, or are you looking for a GLIMMIX task?  There isn't a task in EG for this, but you can run GLIMMIX code in a program window.

Try running this sample program (from the GLIMMIX documentation):

data HessianFly;
     label Y = 'No. of damaged plants'
           n =
'No. of plants';
    
input block entry lat lng n Y @@;
     datalines;
     1 14 1 1  8 2    1 16 1 2  9 1
     1  7 1 3 13 9    1  6 1 4  9 9
     1 13 2 1  9 2    1 15 2 2 14 7
     1  8 2 3  8 6    1  5 2 4 11 8
     1 11 3 1 12 7    1 12 3 2 11 8
     1  2 3 3 10 8    1  3 3 4 12 5
     1 10 4 1  9 7    1  9 4 2 15 8
     1  4 4 3 19 6    1  1 4 4  8 7
     2 15 5 1 15 6    2  3 5 2 11 9
     2 10 5 3 12 5    2  2 5 4  9 9
     2 11 6 1 20 10   2  7 6 2 10 8
     2 14 6 3 12 4    2  6 6 4 10 7
     2  5 7 1  8 8    2 13 7 2  6 0
     2 12 7 3  9 2    2 16 7 4  9 0
     2  9 8 1 14 9    2  1 8 2 13 12
     2  8 8 3 12 3    2  4 8 4 14 7
     3  7 1 5  7 7    3 13 1 6  7 0
     3  8 1 7 13 3    3 14 1 8  9 0
     3  4 2 5 15 11   3 10 2 6  9 7
     3  3 2 7 15 11   3  9 2 8 13 5
     3  6 3 5 16 9    3  1 3 6  8 8
     3 15 3 7  7 0    3 12 3 8 12 8
     3 11 4 5  8 1    3 16 4 6 15 1
     3  5 4 7 12 7    3  2 4 8 16 12
     4  9 5 5 15 8    4  4 5 6 10 6
     4 12 5 7 13 5    4  1 5 8 15 9
     4 15 6 5 17 6    4  6 6 6  8 2
     4 14 6 7 12 5    4  7 6 8 15 8
     4 13 7 5 13 2    4  8 7 6 13 9
     4  3 7 7  9 9    4 10 7 8  6 6
     4  2 8 5 12 8    4 11 8 6  9 7
     4  5 8 7 11 10   4 16 8 8 15 7
   ;

  
ods graphics on;
  
proc glimmix data=HessianFly;
      class block entry;
      model y/n = block entry / dist=binomial link=logit solution;
  
run;
SAS For Dummies 3rd Edition! Check out the new edition, covering SAS 9.4, SAS Viya, and all of the modern ways to use SAS!

View solution in original post

2 REPLIES 2
ChrisHemedinger
Community Manager

Are you trying to run it as a program, or are you looking for a GLIMMIX task?  There isn't a task in EG for this, but you can run GLIMMIX code in a program window.

Try running this sample program (from the GLIMMIX documentation):

data HessianFly;
     label Y = 'No. of damaged plants'
           n =
'No. of plants';
    
input block entry lat lng n Y @@;
     datalines;
     1 14 1 1  8 2    1 16 1 2  9 1
     1  7 1 3 13 9    1  6 1 4  9 9
     1 13 2 1  9 2    1 15 2 2 14 7
     1  8 2 3  8 6    1  5 2 4 11 8
     1 11 3 1 12 7    1 12 3 2 11 8
     1  2 3 3 10 8    1  3 3 4 12 5
     1 10 4 1  9 7    1  9 4 2 15 8
     1  4 4 3 19 6    1  1 4 4  8 7
     2 15 5 1 15 6    2  3 5 2 11 9
     2 10 5 3 12 5    2  2 5 4  9 9
     2 11 6 1 20 10   2  7 6 2 10 8
     2 14 6 3 12 4    2  6 6 4 10 7
     2  5 7 1  8 8    2 13 7 2  6 0
     2 12 7 3  9 2    2 16 7 4  9 0
     2  9 8 1 14 9    2  1 8 2 13 12
     2  8 8 3 12 3    2  4 8 4 14 7
     3  7 1 5  7 7    3 13 1 6  7 0
     3  8 1 7 13 3    3 14 1 8  9 0
     3  4 2 5 15 11   3 10 2 6  9 7
     3  3 2 7 15 11   3  9 2 8 13 5
     3  6 3 5 16 9    3  1 3 6  8 8
     3 15 3 7  7 0    3 12 3 8 12 8
     3 11 4 5  8 1    3 16 4 6 15 1
     3  5 4 7 12 7    3  2 4 8 16 12
     4  9 5 5 15 8    4  4 5 6 10 6
     4 12 5 7 13 5    4  1 5 8 15 9
     4 15 6 5 17 6    4  6 6 6  8 2
     4 14 6 7 12 5    4  7 6 8 15 8
     4 13 7 5 13 2    4  8 7 6 13 9
     4  3 7 7  9 9    4 10 7 8  6 6
     4  2 8 5 12 8    4 11 8 6  9 7
     4  5 8 7 11 10   4 16 8 8 15 7
   ;

  
ods graphics on;
  
proc glimmix data=HessianFly;
      class block entry;
      model y/n = block entry / dist=binomial link=logit solution;
  
run;
SAS For Dummies 3rd Edition! Check out the new edition, covering SAS 9.4, SAS Viya, and all of the modern ways to use SAS!
igforek
Quartz | Level 8

I appreciate your help. It makes sense, because I was unable to find glimmix in the tasks list.

Thank you, you have been very helpful

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

Creating Custom Steps in SAS Studio

Check out this tutorial series to learn how to build your own steps in SAS Studio.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 1370 views
  • 0 likes
  • 2 in conversation