03-05-2015 05:45 AM
I tried to create a bar chart (click on the dataset->Graph->Bar Chart) in SAS EG 7.1 but I'm unable to produce the bar chart in SAS as good as in MS Excel.
Any possibilities to produce the bar chart in EG as similar to the attachment which I did in Excel 2010.
Thanks in advance for your inputs.
03-05-2015 05:58 AM
Well, I dont use EG so cant comment specifically on the functionality, although a Google search had many help documents:
Its a matter of learning Graph Template language and coding, you can then do most things with graphs. For help learning that, have a look through this blog:
03-05-2015 10:16 AM
You don't really need GTL for this simple bar chart. The SGPLOT procedure with the VBAR statement will do it. The KEYLEGEND statement gives you a chance to position the legend outside.
length city $12;
input City $ Headcount;
label headcount='Head Count';
proc sgplot data=headcount;
vbar city / response=headcount name='HC';
xaxis label=' ';
yaxis values=(0 to 140 by 20) label='Head Count' grid;
keylegend 'HC' / location=outside position=right ;
(Note: I will post a screen shot when able to)
03-11-2015 05:27 PM
I thought you already knew how to create a Bar Chart in EG and wanted an alternative. Depending on what exactly you mean by "as good as in MS Excel" you may or may not have to use code. For example, I produced the screenshot below using the Graph Task in EG (after I ran a program to make the HEADCOUNT data).
03-11-2015 06:58 PM
Post under SAS EG instead of Graphs perhaps?
Code will always be more powerful than GUI.
You can check if EG has something called SGDesign which is available in SAS Base to customize graphs afterwards, which is point and click.