Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need to extract specific figures from tabulate

Status
Not open for further replies.

CodeDumb

Technical User
Mar 16, 2008
4
US
Hi, I'm trying figure out how to get just certain figures to return from a tabulate proc. Here's what I'm running:

proc tabulate data=sortdate;
where portalstatusyn=1 and catorg < 5;
class catorg LLOdiff30;
table catorg*(n rowpctn) all*(n pctn),
LLOdiff30 all;
title 'PROC TABULATE output';
run;

And this is a sample of what I'm getting:

Last logon > 30days
0 1 All
Organization

1 N 4.00 3.00 7.00
RowPctN 57.14 42.86 100.00
2 N 1.00 13.00 14.00
RowPctN 7.14 92.86 100.00


What I need is to just have a report of the RowPct of column 1 and the N from column All for each organization. Any help appreciated. I'm just getting started here.
 
Have you tried this?:-
Code:
table catorg*(rowpctn) all*(n), LLOdiff30 all;


Chris
Business Analyst, Code Monkey, Data Wrangler.
SAS Guru.
 
Thanks but that doesn't give me the N for each row, just the total N at the bottom row. I'd like to have the N for each row from the 1 column in place of the RowPctN 0 column. I think I need to look at print or format procs

Last logon > 30days
0 1 All
Organization

1 RowPctN 57.14 42.86 100.00
2 RowPctN 7.14 92.86 100.00
All N 5.00 16.00 21.00
 
Ah, I think I see. I'm going to go play with this a bit using some test data and see what I can do. I'm not sure if it's actually possible using Proc Tabulate.
You might find it easier to get this result using Proc Report instead...

Chris
Business Analyst, Code Monkey, Data Wrangler.
SAS Guru.
 
I did come up with a tabulate proc formatted in a way that helps a lot. Output with ods to html and then opening in excel I have the data in easily selectable columns. I have another issue though that I don't know where to even begin. It's hard to just explain so I'll get something to look at when I get a chance. Thanks for your interest!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top