Data visualization with SAS programming

SAS 9.4 GTL Pie Charts

Reply
Super Contributor
Posts: 333

SAS 9.4 GTL Pie Charts

Is there a way to force the size of the actual pie to be constant across various versions (ie different variables runs) in GTL? Right now it is dependent on the Category label sizes which can change over different variables causing a wide variety of pie sizes.

here is the GTL code that Im using:

proc template;

  define statgraph piechart;

  begingraph / labelplacement=SA;

  dynamic _var _title _sz _dlc _dll;

  entrytitle _title / textattrs=(size=13pt weight=bold);

  layout region;

  piechart category=_var response=percent /

  dataskin=pressed

  stat=sum

  datalabelcontent= _dlc

  datalabellocation= _dll

  datalabelattrs=(size=_sz weight=bold);

  endlayout;

  endgraph;

  end;

run;

Thanks!

EJ

Super Contributor
Posts: 333

Re: SAS 9.4 GTL Pie Charts

I think what Im looking for is something similar to the radius option in gchart but for GTL.

Any ideas?

EJ

Super Contributor
Posts: 333

Re: SAS 9.4 GTL Pie Charts

I just realized I forgot to add my render code above:

proc sgrender data=q1q2 template=piechart;

  where q1 ne '';

  dynamic _var = 'Q1'

  _title = "Q1: How long have you been a Medicaid provider?"

  _sz = '10pt'

  _dlc = 'Percent'

  _dll = 'Auto'

  ;

run;

proc sgrender data=q1q2 template=piechart;

  where q2 ne '';

  dynamic _var = 'Q2'

  _title = "Q2: What is your provider type?"

  _sz = '10pt'

  _dlc = 'Percent'

  _dll = 'Auto'

  ;

run;

SAS Super FREQ
Posts: 1,080

Re: SAS 9.4 GTL Pie Charts

No, there is no RADIUS option for GTL Pie Chart, which is a basic component, without many options.  This is so because Pie Charts are not very commonly used in the statistical domain.  Now, if all your labels are INSIDE, and no other varying size items like legends, you are likely to get the same size pie.

Ask a Question
Discussion stats
  • 3 replies
  • 662 views
  • 0 likes
  • 2 in conversation