BookmarkSubscribeRSS Feed
LorcanOB
Fluorite | Level 6

Using SAS 9.4

 

My research:

I had a group take a test (Baseline)

This group were then given two different drugs

The group then took the test again (FollowUp 1 [for drug 1] and FollowUp 2 [for drug 2])

I want to compare:

(Baseline to FollowUp1) = X

(Baseline to FollowUp2) = Y

Then compare X and Y to see if there was any difference in baseline to followup score changes relating to drug type

 

6 REPLIES 6
Norman21
Lapis Lazuli | Level 10

Of course, you planned your analysis when you designed the experiment.

 

So, what code have your written so far?

Norman.
SAS 9.4 (TS1M6) X64_10PRO WIN 10.0.17763 Workstation

Reeza
Super User

Sounds exactly like this example here:

 

http://documentation.sas.com/?docsetId=statug&docsetTarget=statug_ttest_examples03.htm&docsetVersion...

 

Note that the code is included in the example so you can run the example. 

If you're just getting into SAS the first statistics course is free on the e-learning page.

 


@LorcanOB wrote:

Using SAS 9.4

 

My research:

I had a group take a test (Baseline)

This group were then given two different drugs

The group then took the test again (FollowUp 1 [for drug 1] and FollowUp 2 [for drug 2])

I want to compare:

(Baseline to FollowUp1) = X

(Baseline to FollowUp2) = Y

Then compare X and Y to see if there was any difference in baseline to followup score changes relating to drug type

 


 

LorcanOB
Fluorite | Level 6

Thanks Reeza. I am new (was it that obvious?)

I checked that out before, but I am wondering is there a way to do a comparison of changes within two groups then compare the results of those two comparisons?

 

I have attached sample data

Capture.PNG

Reeza
Super User

Post your data as text please.

 


@LorcanOB wrote:

Thanks Reeza. I am new (was it that obvious?)

I checked that out before, but I am wondering is there a way to do a comparison of changes within two groups then compare the results of those two comparisons?

 

I have attached sample data

Capture.PNG



LorcanOB
Fluorite | Level 6
0 4 8
0 9 9
0 17 17
0 2 0
0 6 11
0 6 6
0 21 21
0 10 5
0 12 9
0 10 11
1 3 2
1 16 13
1 18 14
1 11 12
1 4 3
1 10 7
1 7 13
1 9 11
1 2 6
1 21 21
1 8 8
1 1 8
1 5 6
1 13 8
Reeza
Super User

data have;
input group pre post;
diff = post-pre;
cards;
0 4 8
0 9 9
0 17 17
0 2 0
0 6 11
0 6 6
0 21 21
0 10 5
0 12 9
0 10 11
1 3 2
1 16 13
1 18 14
1 11 12
1 4 3
1 10 7
1 7 13
1 9 11
1 2 6
1 21 21
1 8 8
1 1 8
1 5 6
1 13 8
;
run;

proc anova data=have;
class group;
model diff = group;
means group / tukey;
quit;

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