There is one more way to represent another variable in a chart—you can use the SUBGROUP= option of the VBAR or HBAR statement to specify that you want the bar-plotting symbol (default is *) to represent values of another variable. For example, if you want to see the sales frequencies by REGION and also want to see which items contributed to these sales, you can include ITEM as a subgroup.The modified code is:
ExamplePROC CHART DATA=SALES;
Notice in the following output that the bars are made up of H's (hammers), S's (saws), and P's (pliers).The first letter of each ITEM value is used to create the bars,and the output includes a legend below the graph.
Output from Example - Displaying Groups within a Bar — Character Variable
As you can see, the height of the bars shows the total number of items sold in each of the four regions. The subdivisions within each bar show, by the appropriate charting symbol, how many hammers, pliers, and saws make up this total.
Now what, you might ask, would the system do if the inventory included screwdrivers as well as saws, both beginning with "S." It's simple. The system would simply substitute sequential letters starting with A, B, C, etc. until the series was sufficient to account for all the data. Satisfied?
SAS Programming Related Tutorials
|SASS (Syntactically Awesome Style sheets) Tutorial||R Programming language Tutorial|
SAS Programming Related Interview Questions
|Logistics Interview Questions||SAS Programming,SQL server Interview Questions|
|Clinical SAS Interview Questions||SASS (Syntactically Awesome Style sheets) Interview Questions|
|SQL Server Analysis Services (SSAS) Interview Questions||R Programming language Interview Questions|
|SAS DI Interview Questions||Advanced SAS Interview Questions|
|Base Sas Interview Questions||SAS Macro Interview Questions|
|Clinical Data Management Interview Questions|
Sas Programming Tutorial
Input And Infile
Set, Merge, And Update
Table Lookup Tools
Proc Means And Proc Uimivariate
All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd
Wisdomjobs.com is one of the best job search sites in India.