Hi all, This is my first time posting to the forum but I have found it incredibly helpful in my journey of learning SAS so I thought I would try posting a question I have. I found one similar question in the forum from a few years ago but there was no solution in the thread. I am using SAS 9.4 and am trying to create a clustered bar chart (using sgplot) with a table of values directly below. Using xaxistable, I am able to get the desired result with the exception of one small formatting issue: gridlines. I am not looking to add gridlines to the graph, but to the table below the graph. I inserted a sample dataset and code for what I am doing as well as pictures of the resulting graph and desired formatting changes. Thanks! data sampledata;
input percent 4.1 gender $ group $;
datalines;
15.8 M 1
27.4 M 2
19.6 M 3
25.2 F 2
28.1 F 1
29.6 F 3
;
run;
proc sgplot data=sampledata;
vbar gender / group=group groupdisplay=cluster datalabel datalabelfitpolicy=none response=percent;
xaxis values=("M" "F") display=(nolabel)
valuesdisplay=("Male" "Female") fitpolicy=splitalways;
styleattrs datacolors=(CXFBFFB3 CX68CAB5 CX4376B3);
styleattrs datacontrastcolors=(Black);
xaxistable percent/ pad=15;
run;
... View more