SAS Office Analytics, SAS Add-In for Microsoft Office, and other integrations

Non-Custom Code Way of Specifying % of Another Variable?

Reply
Occasional Contributor tjc
Occasional Contributor
Posts: 7

Non-Custom Code Way of Specifying % of Another Variable?

The Excel Add-In makes it easy to specify that row and column percentages are to be displayed for a given variable. Can the GUI also be used to specify that what's to be displayed is a percentage of another variable? I figured out how to do this with custom code (PCTSUM*), but haven't been able to determine if there's a more straightforward way.
N/A
Posts: 0

Re: Non-Custom Code Way of Specifying % of Another Variable?

is the tagsets.excelXP destination available in that context ?

That allows cells to be defined as formulae

Good Luck

PeterC
SAS Super FREQ
Posts: 8,643

Re: Non-Custom Code Way of Specifying % of Another Variable?

Hi,
I believe the table task or table wizard has the common statistics for percentages available (PCTN, PCTSUM, ROWPCTN, ROWPCTSUM, COLPCTN, COLPCTSUM) with PROC TABULATE. Your only method for specifying a custom denominator is with the angle brackets in PROC TABULATE.

The SAS Add-in for Microsoft Office does NOT receive or generate TAGSETS.EXCELXP output. The only result types for Stored Processes that are available with the SAS Add-in are HTML, CSV or SASReport XML.

Once you are in Excel and using the SAS Add-in to perform tasks or analyze your data -- you are limited to the kind of tasks and wizards that are available with the SAS Add-in. Of course, once you have the results of your analysis in Excel, you could use Excel to calculate the % using an Excel formula.

A different alternative would be to create a Stored Process using either custom PROC TABULATE code or PROC REPORT code to generate the percent you want with SAS.

cynthia
Post a Question
Discussion Stats
  • 2 replies
  • 154 views
  • 0 likes
  • 3 in conversation