BookmarkSubscribeRSS Feed
ammarhm
Lapis Lazuli | Level 10

Hi all,

Need a hand doing this with SAS:

Here is the senario: I have 100 patients who underwent surgery for pain relief, the surgery would shorten a ligament by x centemeters

Pain is measured pre-op (pre_pain) and 1 year post-op (post_pain), so we have a repeated measure sitiation.

The theory is: Is the length of the removed ligament related to pain 1 year after surgery?

Variables I want to correct for: Age and sex

 

So  my understanding is that this needs to be done through mixed modelling to controll for individual patient variation.

somthing like:

 

model post_pain= age sex pre_pain ligament_length (in a mixed model )

 

I have checked alot in the internet but there is not much written on how to do this with SAS, som suggest GLIMMIX, other MIXED etc

 

Would really appreciate your help.

Note: Data is in long form

 

Best regards

AM

 

1 REPLY 1
gergely_batho
SAS Employee

Hi,

I'm not so skilled in mixed modeling, but I think if your model is:

model post_pain= age sex pre_pain ligament_length

than you must have 100 observation, each for a patient, no repeats, and you are using pre_pain as a regular regressor.

I think it is a valid model, and in this case you don't need a mixed model. Just use prog glm. You will look at the p-value of ligament_length.

 

If you want to model it as repeated measures, I would start with this example:

https://support.sas.com/documentation/cdl/en/statug/68162/HTML/default/viewer.htm#statug_mixed_examp...

It's just a technical detail, but you will need to restructure your dataset to have 200 observations, you will drop post_pain, pre_pain, instead you will have PatientID, PrePost, Pain.

 

Proc mixed is for linear models where response variable random term is normaly distributed.

With proc glimmix you are able to model other distributions.

 

Greg

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!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

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
  • 1 reply
  • 666 views
  • 0 likes
  • 2 in conversation