turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Find a Community

- Home
- /
- Analytics
- /
- Stat Procs
- /
- Two sample t-test and z-test.

Topic Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

02-19-2010 07:32 PM

Hi,

I have two samples and I want to test the null hypothesis (mean sample1=mean sample2) using once t-test and then z-test.

For t-test, I use:

proc ttest data=mydata;

var my_variable;

class grouping_variable;

run;

Is it right? the out put is a bit confusing to me. Should I use Pr > |t| or Pr > F to determine the significance of the difference?

Could you please let me know how to run the z-test as well.

Thanks

Malek

I have two samples and I want to test the null hypothesis (mean sample1=mean sample2) using once t-test and then z-test.

For t-test, I use:

proc ttest data=mydata;

var my_variable;

class grouping_variable;

run;

Is it right? the out put is a bit confusing to me. Should I use Pr > |t| or Pr > F to determine the significance of the difference?

Could you please let me know how to run the z-test as well.

Thanks

Malek

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

Posted in reply to deleted_user

02-22-2010 09:11 AM

Pr>|t| is the t-test you are asking about.

Pr>|F| is the comparison of the variances of the two groups.

It isn't strictly proper to do a z-test on data where the std dev is estimated from the sample.

Pr>|F| is the comparison of the variances of the two groups.

It isn't strictly proper to do a z-test on data where the std dev is estimated from the sample.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

Posted in reply to deleted_user

02-22-2010 12:49 PM

To follow-up on Paige's comment, though not strictly proper, the t-distribution converges to the Z-distribution as the sample size goes to infinity so you should reach the same conclusion if the sample size is large.