From: Robin R High on
With ODS there is a very simple way, but as this topic has come up before,
my first question (never answered) is Why? and second, With regards to HO,
what does a pvalue represent?

Robin High
UNMC






From:
df ss <tggsun(a)YAHOO.COM>
To:
SAS-L(a)LISTSERV.UGA.EDU
Date:
01/20/2010 02:09 PM
Subject:
real p values from ttest
Sent by:
"SAS(r) Discussion" <SAS-L(a)LISTSERV.UGA.EDU>



Hi SASor,
I run ttest and get the results. but some of p value from the results are
<.0001. Is there a way to show the real p values (such as
0.00000000000546) to substitute for <.0001?
Thank you,
ss df
From: "Keintz, H. Mark" on
Why would you believe a p value=0.00000000000546?

But maybe what you are trying to do is rank a set
of test results by p-value, and you have a lot of
tests with p < 0.0001, no?

If so, then I ask what sort of data and statistical
tests would provide a meaningful ranking of such
results?


Regards,
Mark

> -----Original Message-----
> From: SAS(r) Discussion [mailto:SAS-L(a)LISTSERV.UGA.EDU] On Behalf Of df
> ss
> Sent: Wednesday, January 20, 2010 3:07 PM
> To: SAS-L(a)LISTSERV.UGA.EDU
> Subject: real p values from ttest
>
> Hi SASor,
> I run ttest and get the results. but some of p value from the results
> are <.0001. Is there a way to show the real p values (such as
> 0.00000000000546) to substitute for <.0001?
> Thank you,
> ss df
>
>
>
From: Mary on
This is done in genetics, but significance is then considered to be very conservative, such as applying a bonferoni correction like 10 -7.

To answer the user's question, if you save the results using ODS, then you'll have the entire p-value and not just the <.01. Such as:

ods output tablename=tablename;
proc procedure;
{steps for procedure}
run;

Then your results will be in the tablename to the left of the equal sign. I posted a complete example of how to do this about a year ago; I'll look for it or you can try to find it in the archives by searching mlhoward(a)avalon.net (but I had a lot of posts last year!)

-Mary

--- rhigh(a)UNMC.EDU wrote:

From: Robin R High <rhigh(a)UNMC.EDU>
To: SAS-L(a)LISTSERV.UGA.EDU
Subject: Re: real p values from ttest
Date: Wed, 20 Jan 2010 14:15:55 -0600

With ODS there is a very simple way, but as this topic has come up before,
my first question (never answered) is Why? and second, With regards to HO,
what does a pvalue represent?

Robin High
UNMC






From:
df ss <tggsun(a)YAHOO.COM>
To:
SAS-L(a)LISTSERV.UGA.EDU
Date:
01/20/2010 02:09 PM
Subject:
real p values from ttest
Sent by:
"SAS(r) Discussion" <SAS-L(a)LISTSERV.UGA.EDU>



Hi SASor,
I run ttest and get the results. but some of p value from the results are
<.0001. Is there a way to show the real p values (such as
0.00000000000546) to substitute for <.0001?
Thank you,
ss df
From: Mary on
I found the post in the archive that saved ttest results to ODS; here's the post again (this was March, 2009)

-Mary

Eduardo,

Here's a more complete example:

data test;
infile cards missover;
input d1 d2 v1 v2;
cards;
1 0 30 20
1 0 29 19
1 0 28 18
0 1 40 20
0 1 41 41
0 1 43 33
;
run;

data dependent_vars;
informat varname $30.;
infile cards missover;
input varname;
obsnum + 1;
cards;
d1
d2
;
run;

ods output position=position;
proc contents varnum data=test;
run;

proc sql noprint;
create table independent_vars as
select variable as varname
from position
where variable not in ('d1','d2');
quit;

data independent_vars;
set independent_vars;
obsnum + 1;
run;

%macro get_results(dependent_var, independent_var);
ods trace on;
proc datasets library=work;
delete ttests equality;
quit;
ods output TTests=ttests Equality=equality;
proc ttest data=test;
class &dependent_var;
var &independent_var;
run;

%let probt=.;
proc sql noprint;
select Probt into :probt
from ttests where variances='Equal';
quit;
%put probt= &probt;

%let probf=.;
proc sql noprint;
select Probf into :probf
from equality where method='Folded F';
quit;
%put probf= &probf;


data results;
dependent_var="&dependent_var";
independent_var="&independent_var";
probt=&probt;
probf=&probf;
run;

data allset;
set allset results;
run;

%mend get_results;

%macro do_calls;

data allset;
stop;
run;

proc sql noprint;
select count(*) as dep_count into :dependant_count
from dependent_vars;
quit;
%put &dependant_count;
proc sql noprint;
select count(*) as dep_count into :independant_count
from independent_vars;
quit;
%put &independant_count;
%do i=1 %to &dependant_count;
%do j=1 %to &independant_count;
proc sql noprint;
select varname into :dependent_var
from dependent_vars
where obsnum =&i;
quit;
%put &dependent_var;
proc sql noprint;
select varname into :independent_var
from independent_vars
where obsnum =&j;
quit;
%put &independent_var;
%get_results(&dependent_var,&independent_var);
%end;
%end;
%mend do_calls;

%do_calls;



-Mary

----- Original Message -----
From: "Eduardo Galvan" <EGalvan(a)SURVEYSCIENCES.COM>
To: <SAS-L(a)LISTSERV.UGA.EDU>
Sent: Monday, March 30, 2009 10:13 AM
Subject: Running/Outputting t-test results repeatedly


Hi,



Sorry for the repost, but I'm hoping somebody can help me with this. I
have 10 dependent variables (e.g., dv1, dv2,....dv10) that I want run
t-tests on and output the mean, standard deviation, and p-value to a
data file. The catch is that I have over 2,000 variables that I want to
use as the independent variable when I am running these tests. In
other words, I need to run 2,000 t-tests on dv1, 2,000 t-tests on dv2,
etc.



Suggestions are appreciated.



Eduardo


--- mlhoward(a)avalon.net wrote:

From: Mary <mlhoward(a)avalon.net>
To: <tggsun(a)YAHOO.COM>
Cc: <SAS-L(a)LISTSERV.UGA.EDU>
Subject: Re: real p values from ttest
Date: Thu, 21 Jan 2010 07:07:51 -0800

This is done in genetics, but significance is then considered to be very conservative, such as applying a bonferoni correction like 10 -7.

To answer the user's question, if you save the results using ODS, then you'll have the entire p-value and not just the <.01. Such as:

ods output tablename=tablename;
proc procedure;
{steps for procedure}
run;

Then your results will be in the tablename to the left of the equal sign. I posted a complete example of how to do this about a year ago; I'll look for it or you can try to find it in the archives by searching mlhoward(a)avalon.net (but I had a lot of posts last year!)

-Mary

--- rhigh(a)UNMC.EDU wrote:

From: Robin R High <rhigh(a)UNMC.EDU>
To: SAS-L(a)LISTSERV.UGA.EDU
Subject: Re: real p values from ttest
Date: Wed, 20 Jan 2010 14:15:55 -0600

With ODS there is a very simple way, but as this topic has come up before,
my first question (never answered) is Why? and second, With regards to HO,
what does a pvalue represent?

Robin High
UNMC






From:
df ss <tggsun(a)YAHOO.COM>
To:
SAS-L(a)LISTSERV.UGA.EDU
Date:
01/20/2010 02:09 PM
Subject:
real p values from ttest
Sent by:
"SAS(r) Discussion" <SAS-L(a)LISTSERV.UGA.EDU>



Hi SASor,
I run ttest and get the results. but some of p value from the results are
<.0001. Is there a way to show the real p values (such as
0.00000000000546) to substitute for <.0001?
Thank you,
ss df