BookmarkSubscribeRSS Feed
sa4co4
Calcite | Level 5

I am new to SAS and I need to calculate Charlson and Elixhauser scores using SAS. Did some tries, successfully imported data, tried to run macro but no luck. Got errors.

 

There are few macros available, but I could not find any tutorials for using them. Could you suggest a relevant tutorial?

1 REPLY 1
ballardw
Super User

@sa4co4 wrote:

I am new to SAS and I need to calculate Charlson and Elixhauser scores using SAS. Did some tries, successfully imported data, tried to run macro but no luck. Got errors.

 

There are few macros available, but I could not find any tutorials for using them. Could you suggest a relevant tutorial?


Large economy sized hint: When running code involving macros and getting errors first set Options mprint; Then run the macro. The log will have details of things as the code is generated by the macro. Then copy all the text generated from the macro, the code, notes, warnings and error messages. Then on the forum open a text box using the </> icon above the message window. Paste all that text. The text box is important because many errors generate diagnostics indicating where the problems are found. The text box will retain formatting so those diagnostics appear in the correct position relative to the code where the main message windows will completely reformat text so the diagnostics are not helpful.

 

Without details I would suspect that however you brought the data into SAS does not match one or more requirements of the macro. Likely candidates are variable values of the wrong type or for ICD related things the actual values. I have seen some interesting ways of representing the same ICD-10 (and ICD-9) code values. Quite often other programs expect the values to look differently.

 

You may need to check with the source of the macro you were using for the data requirements and carefully check your data for compliance.

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 428 views
  • 1 like
  • 2 in conversation