BookmarkSubscribeRSS Feed
Nikos
Fluorite | Level 6

Hi,

I have a dataset which I attach herewith (too many obs).

I use the following three pieces of code to generate graphs and export them to Excel (I use msoffice2k since excelxp tagsets for some reason does not work for me)

Unfortunately the results I am getting are "horrible"..

I am getting:

-- messy huge labels

-- the dataset under the Graph etc..

When I am using the BY Dev_YR_MNTH; then I get 60 graphs while I would wish to have them all in one page side-by-side.

I would very much appreciate if you could help me out to make more presentable the output.

Thank you

Nikos

******************** ( 1 )  *********************************;

ods msoffice2k path="E:\Val_Results"(url=none) file="graph1.html" newfile=output style=normal;

title1 "Amt Development by Age";

symbol1 interpol=join value=dot;

proc gplot data= Test;

  plot Amt*Age=Dev_YR / hminor=0 autovref;

/* by Dev_YR_MNTH;*/

run;

title;

footnote;

ods msoffice2k close;

************************* (  2 )    **********************************************;

ods msoffice2k path="E:\Val_Results"(url=none) file="graph2.html" newfile=output style=normal;

title1 "Amt Development by Age";

symbol1 interpol=join value=dot;

proc gplot data= Test;

  plot Amt*Age=Dev_YR / hminor=0 autovref;

  by Dev_YR_MNTH;

run;

title;

footnote;

ods msoffice2k close;

********************** ( 3 )  ******************************;

ods msoffice2k path="E:\Val_Results"(url=none) file="graph3.html" newfile=output style=normal;

ods listing ;

ods graphics / reset width=11in height=16in;

proc sgpanel data=Test;        /* procedure statement */

  panelby Dev_YR /

novarname spacing=10 rows=5 ; /* classification statement */

  vline  Age /response=Amt group=Dev_YR_MNTH;            /* plot statement */

rowaxis offsetmin=0 offsetmax=.1 max=30;

run;

title;

footnote;

ods msoffice2k close;

*****************************************************;

A part of the data follows since I am not allowed to upload the whole thing


The rest of it goes similarly

  2010-AYMNTH-02   to  2010-AYMNTH-12   for Dev_Years 2010 to 2014 inclusive in total  3.600 Rows


Dev_YR_MNTHAgeLabelDev_YRAmt
2010-AYMNTH-01Age_0010012010 2,850,099
2010-AYMNTH-01Age_0020022010 11,117,981
2010-AYMNTH-01Age_0030032010 34,867,950
2010-AYMNTH-01Age_0040042010 23,447,194
2010-AYMNTH-01Age_0050052010 24,293,656
2010-AYMNTH-01Age_0060062010 32,975,181
2010-AYMNTH-01Age_0070072010 26,220,039
2010-AYMNTH-01Age_0080082010 26,635,979
2010-AYMNTH-01Age_0090092010 31,923,086
2010-AYMNTH-01Age_0100102010 26,892,443
2010-AYMNTH-01Age_0110112010 27,122,684
2010-AYMNTH-01Age_0120122010 30,580,320
2010-AYMNTH-01Age_0130132010 28,245,592
2010-AYMNTH-01Age_0140142010 28,541,518
2010-AYMNTH-01Age_0150152010 30,710,224
2010-AYMNTH-01Age_0160162010 29,069,422
2010-AYMNTH-01Age_0170172010 29,359,624
2010-AYMNTH-01Age_0180182010 30,458,658
2010-AYMNTH-01Age_0190192010 29,542,177
2010-AYMNTH-01Age_0200202010 29,618,125
2010-AYMNTH-01Age_0210212010 30,443,552
2010-AYMNTH-01Age_0220222010 29,660,592
2010-AYMNTH-01Age_0230232010 30,039,276
2010-AYMNTH-01Age_0240242010 30,581,351
2010-AYMNTH-01Age_0250252010 29,989,269
2010-AYMNTH-01Age_0260262010 30,095,406
2010-AYMNTH-01Age_0270272010 30,694,898
2010-AYMNTH-01Age_0280282010 30,182,014
2010-AYMNTH-01Age_0290292010 30,212,399
2010-AYMNTH-01Age_0300302010 30,525,439
2010-AYMNTH-01Age_0310312010 30,195,822
2010-AYMNTH-01Age_0320322010 30,192,999
2010-AYMNTH-01Age_0330332010 30,499,030
2010-AYMNTH-01Age_0340342010 30,411,645
2010-AYMNTH-01Age_0350352010 30,399,975
2010-AYMNTH-01Age_0360362010 30,504,148
2010-AYMNTH-01Age_0370372010 30,384,613
2010-AYMNTH-01Age_0380382010 30,346,111
2010-AYMNTH-01Age_0390392010 30,441,818
2010-AYMNTH-01Age_0400402010 30,309,287
2010-AYMNTH-01Age_0410412010 30,319,272
2010-AYMNTH-01Age_0420422010 30,422,982
2010-AYMNTH-01Age_0430432010 30,316,635
2010-AYMNTH-01Age_0440442010 30,311,218
2010-AYMNTH-01Age_0450452010 30,418,184
2010-AYMNTH-01Age_0460462010 30,268,734
2010-AYMNTH-01Age_0470472010 30,253,868
2010-AYMNTH-01Age_0480482010 30,424,075
2010-AYMNTH-01Age_0490492010 30,326,897
2010-AYMNTH-01Age_0500502010 30,378,397
2010-AYMNTH-01Age_0510512010 30,472,322
2010-AYMNTH-01Age_0520522010 30,366,263
2010-AYMNTH-01Age_0530532010 30,366,263
2010-AYMNTH-01Age_0540542010 30,471,581
2010-AYMNTH-01Age_0550552010 30,523,409
2010-AYMNTH-01Age_0560562010 30,522,997
2010-AYMNTH-01Age_0570572010 30,529,264
2010-AYMNTH-01Age_0580582010 30,559,098
2010-AYMNTH-01Age_0590592010 30,559,098
2010-AYMNTH-01Age_0600602010 30,573,054






2 REPLIES 2
Reeza
Super User
60 graphs while I would wish to have them all in one page side-by-side.

Can you explain what you mean by that?

You want 60 graphs on one page, or 60 lines on one graph?

Can you post a sample of what you're looking to achieve?

DanH_sas
SAS Super FREQ

Try your SGPANEL code again; but, on the PANELBY statement, add the option ONEPANEL. That will force all of the panel cells to be on one page. Be sure you make the width and height big enough to hold them. Hope this helps!

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!

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.

SAS Training: Just a Click Away

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

Browse our catalog!

Discussion stats
  • 2 replies
  • 1180 views
  • 0 likes
  • 3 in conversation