BookmarkSubscribeRSS Feed
tal83
Calcite | Level 5
Hi:)
When I use Greplay to display few graph in one template - it doesn't look good.(It's horizontal size is about twice the vertical size. i want the vsize to be about 0.75 of the hsize-BTW, its very complicated to explain how my graph look, without adding a picture 🙂 )
I tried to use hsize&vsize options on the 2 graphs i want to display later on, but it doesn't seem to affect anything ( The graph i create are the size i want, but not when i replay them together in a template). I also tried to use this options before replaying the graph, but again seems like the option is ignored.


Thanks in advance!
goptions hsize=5 vsize=4;
symbol1 i=join v='dot' c=black H=0.15 cm;
axis1 order=('1Jan2000'd to '1Jan2005'd by year)
label=(f=swiss h=0.4 cm 'Date') minor=none;
axis2 order = (0 to 1.75 by 0.25)
label=(f=swiss h=0.4 cm a=90 'NOx Monthly Mean [ppb]');

legend1 label=none value=('Seasonal Factors' );
/*title1 "Seasonal Factors of NOx [ppb] monthly mean";*/
/*title2 "&name. (station &stat.)"; */
proc gplot gout=/*x12.nox_mean_SF&stat.*/ work.grep data=x12.X12_nox_mean;
plot NOX_mean_b1_d10 * date = 1
/ overlay legend=legend1
vaxis = axis2 haxis=axis1 name="noxm&stat.SF" vref=1;
where stat_id=&stat.;
run; quit;


goptions hsize=5 vsize=4;
symbol1 i=join v='dot' c=black H=0.15 cm;
axis1 order=('1Jan2000'd to '1Jan2005'd by year )
label=(f=swiss h=0.4 cm 'Date') minor=none;
axis2 order = (0 to 2.75 by 0.25)
label=(f=swiss h=0.4 cm a=90 'NOx Monthly Mean [ppb]');
legend1 label=none value=('Irregular Component' );
/*title1 "Irregular component of NOx [ppb] monthly mean";*/
/*title2 "&name. (station &stat.)"; */
proc gplot gout=/*x12.nox_mean_irreg&stat.*/work.grep data=x12.X12_nox_mean;
plot NOX_mean_b1_D13 * date = 1
/ overlay legend=legend1
vaxis = axis2 haxis=axis1 name=/*"&stat.Noxmean "*/"noxm&stat.irr";
where stat_id=&stat.;
run; quit;



/*goptions hsize=5.5 vsize=5.5;*/
proc greplay nofs tc=sashelp.templt;
list tc;
preview v3s;
run;
quit;
%let name=multi;
filename odsout '.';
GOPTIONS DEVICE=gif;
ODS LISTING CLOSE;
ODS HTML path="C:\temp"
nogtitle gfootnote;
goptions display;
proc greplay igout=work.grep tc=sashelp.templt template=v2s nofs;
treplay 1:Noxm28sf
2:Noxm28ir



name="NOxMe28"
des=""
;
run;
quit;
ODS HTML CLOSE;
ODS LISTING;
2 REPLIES 2
Cynthia_sas
SAS Super FREQ
Hi:
Is it a typo that you preview v3s, but replay into v2s???? Did you want v3s or v2s???

You can always design your own greplay template by specifying the X/Y coordinates of the replay "areas", but unless you are doing a "one for one" template, of necessity, your original graphs are scaled to fit inside the template areas. In my experience, it's more important to create the original graphs in the correct orientation (landscape vs portrait) if I'm using GREPLAY. If I create them in any particular size, I create them very close to the size that they're going to be in the final GREPLAY template.

For example, if you were going to use a 4-up template like the one shown on this page:
http://support.sas.com/documentation/cdl/en/graphref/61884/HTML/default/greplay-overview.htm

It will work best for the replay if the original 4 templates are in a landscape orientation so they scale appropriately for the landscape 4-up greplay template.

And as it explains here:
http://support.sas.com/documentation/cdl/en/graphref/61884/HTML/default/greplay-concepts.htm

Sizing and Naming Your Graphs for Replay (Best Practice)

To replay your graphics output using the GREPLAY procedure, it is recommended that you do the following:

Select or create a template to replay your graphs. Determine the size of each panel contained in the template. Define the size of each graph to correspond to the size of a panel contained in the template. Size each graph with GOPTIONS such as the XPIXELS= and YPIXELS= options or the HSIZE= and VSIZE= options. If the graphs that you are replaying are too large for the panels in the template, SAS/GRAPH attempts to resize the images.



Here are some useful papers on using GREPLAY:
http://www2.sas.com/proceedings/sugi25/25/iv/25p165.pdf
http://analytics.ncsu.edu/sesug/2002/GR01.pdf
http://www.nesug.org/Proceedings/nesug98/invi/p128.pdf
http://www.nesug.org/proceedings/nesug99/cc/cc105.PDF
http://www2.sas.com/proceedings/forum2008/222-2008.pdf
http://www.lexjansen.com/pharmasug/2009/cc/cc09.pdf

cynthia
tal83
Calcite | Level 5
Thanks!
The preview was only to display the list of the template options.
I had no idea that I could create my own template. Thanks, I'm studying this now- and i'll try tofix my problem later on.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

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

View all other training opportunities.

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