Reputation: 125
I am aware this is a very naive question, however I am trying to find a way to export T-Test statistics to a simple output dataset. For example, I have the following code being run now:
proc ttest plots(only) = (summary) data = work.mydf;
options orientation = landscape;
class byvar;
var var1 var2;
ods output statistics = outputdf;
by UNIT_ID;
run;
The ods output statistics = outputdf
yields a dataset with upper an lower confidence intervals, mean of the two groups, upper and lower limit of STD...etc.
I need a dataset with p-values from the test of equality of variances. Any help is appreciated.
Upvotes: 2
Views: 7267
Reputation: 63434
The way you answer this is typically to add
ods trace on;
before you run it once. Then the log will report all of the different tables that the proc outputs, and you can add ods output statements for them.
In this case you see, among other things in the log:
Output Added:
-------------
Name: Equality
Label: Equality of Variances
Template: Stat.TTest.Equality
Path: Ttest.MPG_Highway.Equality
This means you need to add equality
(the Name:
above) to your ods output
statement and give it a dataset name to output to.
ods output statistics = outputdf equality=outputeq;
Upvotes: 4