BookmarkSubscribeRSS Feed
greerham
Calcite | Level 5

Hi-I could use some help. I need to preform a statistical analysis to assess the association between type of insurance (categorical) and the outcome of diabetes status at visit 3 (binary variable). The diabetes status of interest is Yes (which are all of the responses).

 

I wrote my code as... proc logistic data=jhst_proj2final; class PRIVATEPUBLICINSV3; model DIABETESV3(event='Yes')=PRIVATEPUBLICINSV3; run;

 

But I keep getting this error message "ERROR: All observations have the same response. No statistics are computed."

 

I am trying to figure out if the analysis I selected is wrong or if the code is wrong.

3 REPLIES 3
ballardw
Super User

Try running this code:

 

Proc freq data=jhst_proj2final;

   tables PRIVATEPUBLICINSV3*DIABETESV3 / list missing;

run;

That will show all of the combinations of your, I assume, insurance variable with the diabetes variable. If all of the diabetes are "yes" then that is the issue. Likely you need to go back to what created the diabetes variable and see why all the values are "yes".

 

Another possibility would be that the insurance is missing for all of the "No" diabetes responses.

greerham
Calcite | Level 5

I figured it out, thank you!

ballardw
Super User

@greerham wrote:

I figured it out, thank you!


Please describe what you figured out.

That way when someone finds a link to this thread in an internet search later with a similar problem they will have at least one possible solution to their problem.

SAS INNOVATE 2024

Innovate_SAS_Blue.png

Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.

If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website. 

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.

Get the $99 certification deal.jpg

 

 

Back in the Classroom!

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

View all other training opportunities.

Discussion stats
  • 3 replies
  • 291 views
  • 2 likes
  • 2 in conversation