BookmarkSubscribeRSS Feed
Obsidian | Level 7

The STAR-chart in PROC GCHART does not draw lines from the origin to the points on the enclosing circle. I did not find an option to include such lines. Therefore I am trying to draw these radial lines with Annotate. However, so far I was not able to pick up the location of the origin (center) nor the radius of the enclosing circle. Any suggestion how to do that?

Opal | Level 21

Are you just looking for how to include the lines (e.g., the noconnect option) or combining the two?  If it is the former, take a look at:

Obsidian | Level 7

No, that is not what I want.

Below is the first picture of that article. I added the lines that I want in RED. The run from the center to each of the midpoint markers on the enclosing circle. In addition to the lines I also want to add tickmarks to the lines, but I suppose that when I am able to create the lines adding the tickmarks is not a major problem.


Super User

You may want to investigate GRADAR as it does the spokes and allows ticks on them. There are differences in how groups are displayed but without data examples it's hard to tell if that'll work.

Obsidian | Level 7

That would be an option in some situations, but the challenge remains: how do I get the right co-ordinates for the various points in a STAR-chart. Although drawin radial lines is probably not very relevant to PIE-charts, the general problem how to position annotate elements in PIE- and START-charts remain.

Opal | Level 21


proc gchart and annotate are definitely not amongst my specialties, thus you may want to simply disregard what I have to say regarding your problem.  I came awfully close to producing what you want, but in a rather odd and incomplete way.  However, as you haven't received an answer yet, I figure I may at least share the method .. as forceful and incomplete as it is.  Hopefully, minimally, you might be able to use it to help discover what you are missing.

data meetings;

  informat date mmddyy10.;

  format date mmddyy10.;

  input (Dept Room) ($) Room_Number Date Hours;


ACCOUNTS    C339      339     01/10/1995     1.00

ACCOUNTS    B100      100     01/24/1995     0.50

SHIP        C339      339     01/30/1995     2.00

MARKET      C301      301     02/24/1995     3.50

SHIP        C339      339     02/28/1995     4.00

MARKET      C301      301     03/01/1995     4.00

ACCOUNTS    B100      100     03/03/1995     3.50

ACCOUNTS    B100      100     03/08/1995     0.50

ACCOUNTS    B100      100     03/21/1995     0.25

SHIP        C301      301     03/27/1995     1.50

ACCOUNTS    C301      301     03/29/1995     0.50

SHIP        C339      339     04/12/1995     0.50

MARKET      C301      301     04/25/1995     1.50

MARKET      B100      100     05/02/1995     0.50

SHIP        C301      301     05/12/1995     2.50

MARKET      C301      301     05/25/1995     3.50

SHIP        C301      301     06/01/1995     2.00

SHIP        C339      339     06/07/1995     3.00

SHIP        C301      301     06/14/1995     2.00

MARKET      C339      339     07/12/1995     0.50

ACCOUNTS    B100      100     08/03/1995     3.00

SHIP        C301      301     08/14/1995     2.50

SHIP        C339      339     08/28/1995     1.50

MARKET      C339      339     09/15/1995     3.00

ACCOUNTS    C301      301     09/28/1995     0.50

MARKET      C301      301     10/11/1995     3.00

SHIP        C301      301     11/01/1995     1.50

MARKET      C339      339     11/15/1995     1.00

SHIP        B100      100     11/21/1995     2.00

SHIP        C339      339     11/22/1995     3.50

MARKET      C339      339     12/05/1995     2.50

MARKET      C301      301     12/21/1995     2.50


proc summary data=meetings;

  var hours;

  class room;

  output out=props n=;


data props;

  set props;

  retain total;

  if _n_ eq 1 then total=hours;

  else do;





proc sql;

  create table meetings2 as

    select a.*,b.prop

      from meetings as a,

           props as b

        having eq



goptions nodisplay htext=13pt htitle=15pt;


pattern1 color=graydd; pattern2 color=VLIB; 

pattern3 color=PALG;

title1 "Lengths of Meetings by Room";

proc gchart data=meetings2;

star room / noheading name="starA"

sumvar=hours fill=s coutline=black woutline=1;

run; quit;


proc gchart data=meetings2;

  star room / noheading name="starB"

  sumvar=prop fill=x noconnect

/*  percent=none value=none*/


  coutline=red woutline=1;

run; quit;

filename chrt34 'c:\art\chrt34.emf';

goptions display gsfname=chrt34 gsfmode=replace;

proc greplay nofs igout=work.gseg tc=tempCat;

tdef T1X1

1/llx=0 ulx=0 urx=100 lrx=100

   lly=0 uly=100 ury=100 lry=0;


treplay 1:StarA 1:StarB;

run; quit;

Obsidian | Level 7


I see what you do. And yes this may work, provided that you keep the graphics environment equal, in order to keep the size and position of the two charts that you are stacking identical. But what about adding other elements to a PIE or START chart. I assume there must be some method in the Annotate facility to find the right co-ordinates of the center and the radius of the enclosing circle?!

Opal | Level 21

Erik,  I will have to leave your question for someone who is more familiar with SAS/graph and annotate than I am.  I produced my pseudo solution to your problem this morning, but didn't post it as I was hoping that some "real" graph experts my provide the "real" answer.

Unfortunately, you may have to wait until after the holidays, which is why I decided to share my feeble attempt.

Obsidian | Level 7


Much appreciated!

It can wait for some time.  There are several other topics I can work on.

Best wishes for 2012 to you and any other reader of this.

Obsidian | Level 7

Has anybody a suggestion?

Rhodochrosite | Level 12

hi ... the big problem with using annotate to modify a star chart is that the data coordinate system cannot be used, so you'd have to figure out the locations of anything that has to be tweaked based on percentages of output area and that'll vary from chart to chart

so, Art's overlay solution is a lot easier than annotate (but pretty limited as to what you can accomplish)



Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.

If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website. 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Get the $99 certification deal.jpg



Back in the Classroom!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 10 replies
  • 4 in conversation