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

Good afternoon all. I'm writing because I am analyzing complex survey data, and trying to run PROC SURVEYFREQ to analyze depression and anxiety by self-rated health. When I attempt to run it, SAS Studio softlocks, as it keeps waiting but never actually gets anywhere. I don't get any error screens or anything. The other survey procedures (PROC SURVEYLOGISTIC) work fine. Here is my code (though I don't think the issue is the code itself):

 

PROC SURVEYFREQ Data=Hlth.MHlth;
TABLES health*depression health*anxiety;

STRATA stratum;
WEIGHT fsweight;
CLUSTER psu;
TITLE "Health by Depression Tables";
RUN;

 

I appreciate any advice you might have on this, as I am completely stumped.

1 ACCEPTED SOLUTION

Accepted Solutions
RTurpin
Fluorite | Level 6

Thanks all, I think I figured it out: PROC SURVEYFREQ just runs incredibly slowly on SAS Studio. It eventually worked after a very long wait period.

 

Thanks,

Rod Turpin

View solution in original post

5 REPLIES 5
Reeza
Super User

Are you using SAS UE?

 

How big is your dataset?


Can you run the PROC SURVEYFREQ from the examples?

RTurpin
Fluorite | Level 6

Thanks for the quick reply. I am using SAS University Edition, and it's a small dataset wiuth ~500 observations. Also, it seems to not work when I use the stratum and cluster statements together. If I use the weight and cluster statements, or the weight and stratum statements, it runs fine.

Reeza
Super User

So, SAS Studio isn't good at always throwing errors, sometimes it freezes and that's what you're running into. 

There is a mistake somewhere in the logic/code, but I don't the proc well enough to comment on that portion.

ballardw
Super User

I think you need a TOTAL dataset on the proc statement to the total number of clusters in the population for each level of the STRATA variable.

RTurpin
Fluorite | Level 6

Thanks all, I think I figured it out: PROC SURVEYFREQ just runs incredibly slowly on SAS Studio. It eventually worked after a very long wait period.

 

Thanks,

Rod Turpin

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

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
  • 5 replies
  • 1264 views
  • 0 likes
  • 3 in conversation