BookmarkSubscribeRSS Feed
BMuel
Calcite | Level 5


Hi, I'm pulling my hair out any help would be appreciated as I'm not a sas programmer. I want to run a gchart  on a grouped  but I want the htm file to be populate based on another field in that data sorted descending, here are examples of data and basic gchart.

     DATE    SUBFUNC      MIPS

05MAY2014    ACTXXX       0.05

06MAY2014    ACTXXX       0.06

07MAY2014    ACTXXX       0.04

08MAY2014    ACTXXX       0.06

05JUN2014    ADTXXX       0.01

06JUN2014    ADTXXX       0.01

07JUN2014    ADTXXX      0.01

08JUN2014    ADTXXX       0.01

05JUL2014    COMPXXX     27.08

06JUL2014    COMPXXX     23.16

07JUL2014    COMPXXX     51.50

08JUL2014    COMPXXX     49.08

05JUL2014    EDITXXX     15.78

06JUL2014    EDITXXX     14.07

07JUL2014    EDITXXX     31.28

08JUL2014    EDITXXX     31.41

PROC GCHART DATA=damips;           

  by subfunc;                      

TITLE " Mips per Subfunction";    

  VBAR3D date /                    

  raxis=axis3                      

  autoref                          

  discrete                         

  name="damips"                    

  sum                              

  GROUP=subfunc                    

  SUMVAR=mips                     

My problem is the the htm file is being populated is based on subfunc sort order and I would like to have the mips descending be the order the charts appear in the htm file. Does that make sense?

2 REPLIES 2
ballardw
Super User

Using "By Subfunc" pretty much means that is the sort order of the charts. I can't quite visualize what you want with reference to "mips descending order". Can you make a dummy example of what you would expect this to look like using another program?

Often to control orders of appearance you may need to pre-summarize or add order or dummy values for variables depending on the specific appearance wanted.

BMuel
Calcite | Level 5

Hi ballardw,  after reviewing what I wrote I see it was a terrible description my apologies. I'm creating vbar charts of daily mips for each subfunc, 60-80 of them. Some of these subfuncs use .01 mips per day and others can use 1000 mips per day. I want my HTM output file to have the higher daily mip subfuncs at the top of the report, right now sorted by subfunc they're all at the bottom of the htm file, I have to page down to bottom to see the heavy hitters 'high mips' subfuncs, all start down around P or so.

Does that make more sense? I am currently looking at ranking the subfunc based on mips but I don't know how I'd run that through gchart and still have the report based on sunfunc. Thanks for your time.

SAS Innovate 2025: Register Now

Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 870 views
  • 0 likes
  • 2 in conversation