Date: Wed, 17 Jan 2007 08:42:18 -0800
Reply-To: "Dennis G. Fisher, Ph.D." <dfisher@CSULB.EDU>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "Dennis G. Fisher, Ph.D." <dfisher@CSULB.EDU>
Subject: Re: proportions test in SAS
In-Reply-To: <cabe11870701170819w3166582ejc51a274f3fa5b2a6@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Zack gave you the easy and correct answer. Basically, do your chi
square and examine the individual cells.
The hard way (and possibly correct also) answer
is to use PROC CATMOD. To do this, you really need to work with someone
who is
an expert at log-linear modeling.
Dennis Fisher
baogong jiang wrote:
> Zack:
>
> Thank you for your suggestions. my problem is: I know that the race
> proportion is defferent in all regions. like we know in the
> population, it's
> about 60% are white, 35% are black and 5% are others.
> In real word, region 1 have 61%: 34%:5%
> regioln 2 have 63%:32%:5%
> region3 have 60%:38%:2%
> region4 have 55%:30%:15%
>
> I want to know if the race proportions is differrent in those 4 regions.
> like above sample, I think region 4 has different race propotions
> compare to
> other regions.
>
> regards,
>
> baogong
>
>
> On 1/17/07, Zack, Matthew M. (CDC/CCHP/NCCDPHP) <mmz1@cdc.gov> wrote:
>>
>> As others have suggested, simply use PROC FREQ (cf., attachments).
>>
>> The CHISQ option for the TABLES statement calculates chi-square
>> statistics.
>>
>> The EXPECTED option for this statement calculates the expected frequency
>> in each cell of the 4*3 table under the independence assumption [=the
>> proportions
>> of the different race groups in the different regions are the same].
>> These expected frequencies should be compared to the observed
>> frequencies
>> in the same cell to determine whether the observed frequencies are
>> greater than,
>> less than, or almost equal to these expected frequencies.
>>
>> The CELLCHI2 option calculates each cell's contribution to the overall
>> chi-square statistic for the table. Any values exceeding 3.841 indicate
>> that the observed cell frequency differs statistically significantly
>> from that expected under the independence assumption.
>>
>> The displayed row percents for each cell confirm the chi-squared
>> statistics
>> for each cell because the row percents for each race differ across the
>> regions.
>> Thus, the proportions of the different race groups in the different
>> regions
>> are NOT the same.
>>
>> Matthew Zack
>>
>> -----Original Message-----
>> From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of
>> baogong jiang
>> Sent: Wednesday, January 17, 2007 9:05 AM
>> To: SAS-L@LISTSERV.UGA.EDU
>> Subject: Re: proportions test in SAS
>>
>> Thank you all for your suggestions. May be I did not describe my problem
>> clearly, I am looking for an ANOVA like test to test the hypothesis: the
>> proportions of different race (white, black, other) in different regions
>> are the same.
>>
>>
>>
>> Can I use Logistic regression to test this hypothesis by considering
>> race (white, black, other) as multinomial outcome.
>>
>>
>>
>> *proc* *logistic* data=data rorder=data;
>>
>> class region ;
>>
>> model race=region;
>>
>> weight recip_no;
>>
>> *run*;
>>
>>
>>
>> or Can I use proc genmod to test the hypothesis like the following code:
>>
>> *proc* *genmod* data=data rorder=data;
>>
>> freq recip_no;
>>
>> class region;
>>
>> model race = region / dist=multinomial
>>
>> link=cumlogit
>>
>> aggregate=region
>>
>> type3;
>>
>> *run*;
>>
>>
>>
>> Thank you very much,
>>
>> baogong
>>
>>
>> On 1/17/07, LWn <lars.wahlgren.withoutthispart@stat.lu.se> wrote:
>> >
>> > Or perhaps this is what you're looking for:
>> >
>> > proc freq data=data ;
>> > weight recip_no ;
>> > table region*race
>> > / nopercent nocol chisquare ;
>> > run ;
>> >
>> > HTH / LWn
>> >
>> > "baogong jiang" <bgjiang@GMAIL.COM> skrev i meddelandet
>> > news:cabe11870701161316v6dcc790bha718f86f0bbba2b9@mail.gmail.com...
>> > > Hello:
>> > >
>> > > Anyone knows how can I test if the proportion of the race is
>> > > different
>> > in
>> > > all the regions?
>> > > my data:
>> > >
>> > > DATA DATA;
>> > > input region $ race $ recip_no;
>> > > CARDS;
>> > > region1 white 850
>> > > region1 black 250
>> > > region1 other 120
>> > > region2 white 889
>> > > region2 black 212
>> > > region2 other 125
>> > > region3 white 550
>> > > region3 black 150
>> > > region3 other 80
>> > > region4 white 1520
>> > > region4 black 1250
>> > > region4 other 120
>> > > ;run;
>> > >
>> > >
>> > > thank you,
>> > >
>> > > baogong
>> >
>>
>>
>>
>> --
>> Baoogng Jiang
>> Department of Agronomy
>> Lousisana State University
>>
>>
>>
>>
>>
>
>
> --
> Baoogng Jiang
> Department of Agronomy
> Lousisana State University
>
>
|