|
|
Re: proc tabulate #2
I simply want to know the number (N) of people
hospitalized by sex and grp.
Liyan
--- Liyan Liu <liyanliu888@yahoo.com> wrote:
> Dear fellow SAS professionals,
>
> I have a dataset with 3 variables
> hosp -- hospitalized for at least once (1,0)
> sex -- m,f
> grp -- 1,2,3
>
> How could I use the PROC TABULATE procedure to
> produce
> a table like:
>
>
-----------------------------------------------------
> m f
> total
> -------------- -------------------
> grp1 grp2 grp3 grp1 grp2 grp3
>
-----------------------------------------------------
> hosp
> 1
> 0
>
-----------------------------------------------------
> Inside the table is the number of people
> hospitalized.
> Thanks so much.
>
> Liyan
>
> __________________________________
> Do you Yahoo!?
> The New Yahoo! Shopping - with improved product
> search
> http://shopping.yahoo.com
>
__________________________________
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search
http://shopping.yahoo.com
|
|
0
|
|
|
|
Reply
|
liyanliu888 (12)
|
10/2/2003 11:39:22 PM |
|
"Liyan Liu" wrote
> I simply want to know the number (N) of people
> hospitalized by sex and grp.
data h;input hosp sex $ grp;
_n=1; *does value 1/0 mean something in hosp?;
*if hosp = 1;
cards;
1 m 1
0 m 0
1 f 2
0 f 3
1 m 3
0 m 3
;
proc tabulate noseps formchar=' ';
class hosp sex grp;var _n;
table sex all, _n='#'*F=3. * (n=' ' pctsum<sex all>='%'*F=6.2) /rts=5
condense;
table grp all, _n='#'*F=3. * (n=' ' pctsum<grp all>='%'*F=6.2) /rts=5
condense;
table sex*grp all, _n='#'*F=3. * (n=' ' pctsum<sex*grp all>='%'*F=6.2)
/rts=5 condense;
run;
|
|
0
|
|
|
|
Reply
|
arto.raiskio (87)
|
10/3/2003 12:03:58 AM
|
|
|
1 Replies
54 Views
(page loaded in 0.038 seconds)
Similiar Articles: Create an HTML report from this dataset - comp.soft-sys.sas ...proc tabulate data=cars /* formchar(1,2,3,4,5,6,7,8,9,10,11) ='*****'*/; class car ... Re: PROC SQL & Macro Quoting - comp.soft-sys.sas... are found, they ... Re: Creating one report with columns based on different subsets ...Proc Tabulate - comp.soft-sys.sas Re: Creating one report with columns based on different subsets ... Date: Wed, 30 Dec 2009 22:17:04 -0500 This is a natural for PROC ... Re: proc factor with missing data? - comp.soft-sys.sasRe: PROC NLP and R^2 - comp.soft-sys.sas I may have ... ... needed please. - comp.soft-sys.sas Re: proc factor with missing data? - comp.soft-sys.sas Re: Proc tabulate ... Re: PROC EXPORT excel formatting in SAS 9.2 on x64 - comp.soft-sys ...Re: PROC EXPORT excel formatting in SAS 9.2 on x64 - comp.soft-sys ... Each ... ... TABULATE treats observations with negative weights ... first uses the user-defined ... SAS Beginner Pls Help - comp.soft-sys.sas... 22-26 Type $ 28-30 Price $ 32-36; * Tabulations with two dimensions and statistics; PROC TABULATE ... on DDE 'excel SAS Beginner Pls Help - comp.soft-sys.sas Re: Proc ... Proc Tabulate - comp.soft-sys.sasI have heard that I can make proc tabulate calculate the ratio of two columns, but I can't figure out ... Re: Creating one report with columns based on different subsets Why won't SAS fix PROC EXPORT - comp.soft-sys.sas... PROC EXPORT excel formatting in SAS 9.2 on x64 - comp.soft-sys ..... of other DBMS and VERSIONS, with no success > (some won't run, others won't ... Re: PROC TABULATE ... How to generate a table with proc means - comp.soft-sys.sas ...Surveylogistic help - comp.soft-sys.sas... help - comp.soft-sys.sas Re: proc ... SAS FAQ: How can I create tables using proc tabulate? Below we use proc means to create ... Data Structure Using Proc Transpose - comp.soft-sys.sasIn those cases you should step back and consider using Proc TABULATE or REPORT to ... SAS-L@listserv.uga.edu> Sent: Tuesday, March 09, 2010 12:03 Subject: Re: Using PROC ... PROC Freq - Output - comp.soft-sys.sasHello, This might be a simple PROC question ... Re: PROC FREQ v9.2 error win xp/sp2 or win7 - comp.soft-sys.sas ... Proc Tabulate - comp.soft-sys.sas How to generate a table ... SUGI 27: Anyone Can Learn PROC TABULATE2 PROC TABULATE DATA=TEMP; VAR RENT; TABLE RENT*MEAN; RUN; The ... you’re probably asking yourself, “Why use PROC TABULATE? Everything I’ve seen so far could be done Re: proc tabulate, sum/pctsum question - RhinocerusOn Fri, 2 May 2008 18:49:56 +0300, Mugu Gai Pan <mugu@PCN.NO> wrote: >suppose I had the following data > >data test;input color blend $ 7/23/2012 2:44:15 AM
|
|
|
|
|
|
|
|
|