<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: how to put multi plots in 1 rtf? in Graphics Programming</title>
    <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556885#M18099</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/224340"&gt;@magicdj&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;the problem is that different plots prefer to have different scale. sgpanel&amp;nbsp; only has fixed scale on left side, even using spacing option.&lt;/P&gt;
&lt;P&gt;not each cell have it's own scale.&lt;/P&gt;
&lt;P&gt;for GTL, I don't know how to use IF option. my code in first post is not working properly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thanks for your help.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;The PANELBY option UNISCALE sets which axes are identical. The default is all but if you use UNISCALE=COLUMN only the X axis will have the same scale within each row. So with a single column each panel would likely have a separate Y axis if the data required it.&lt;/P&gt;</description>
    <pubDate>Tue, 07 May 2019 17:19:27 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2019-05-07T17:19:27Z</dc:date>
    <item>
      <title>how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556456#M18087</link>
      <description>&lt;P&gt;&amp;nbsp; I need to put several line plots in one page, in rft format. I searched several posts but they are only working in pdf.&lt;/P&gt;&lt;P&gt;I&amp;nbsp;made some codes below, but not sure how to apply if condition in gtl. also I want to different color for each model in line plots.&lt;/P&gt;&lt;P&gt;any help? thanks a lot.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ods _all_ close;

* set papersize etc. for PDF ;
options orientation=LANDSCAPE;


data cars;
  set sashelp.cars;


  run;



*;
ods rtf file="c:\individual_rtftet.rtf";



proc template;
  define statgraph plot_linearlog;
    begingraph;

      layout lattice / rows = 2 columns = 3;
if (make='Acura' )
        layout overlay / xaxisopts=(type = linear);
		
       seriesplot x= Horsepower y=MPG_City / name="series" ;
     endlayout;
endif;
		if (make='Audi' )
 
        layout overlay / xaxisopts=(type = linear);
      seriesplot x= Horsepower y=MPG_City / name="series" ;
     endlayout;
endif;

	if (make='BMW' )
 
        layout overlay / xaxisopts=(type = linear);
      seriesplot x= Horsepower y=MPG_City / name="series" ;
     endlayout;
endif;

	if (make='Buick' )
 
        layout overlay / xaxisopts=(type = linear);
      seriesplot x= Horsepower y=MPG_City / name="series" ;
     endlayout;
endif;
   endlayout;
 endgraph;
  end;
run;
quit;

proc sgrender data = sashelp.cars template = plot_linearlog;
run;

ods rtf close;

&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 06 May 2019 15:31:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556456#M18087</guid>
      <dc:creator>magicdj</dc:creator>
      <dc:date>2019-05-06T15:31:01Z</dc:date>
    </item>
    <item>
      <title>Re: how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556557#M18091</link>
      <description>&lt;P&gt;Before going to all that (repetitive) coding in GTL I suggest looking at Proc SGPANEL first.&lt;/P&gt;
&lt;P&gt;Example&lt;/P&gt;
&lt;PRE&gt;proc sort data=sashelp.cars
   out=work.cars
;
   by make horsepower;
run;


proc sgpanel data=work.cars;
  where make in ('Acura' 'BMW' 'Buick');
  panelby make / columns=1
  ;
  series x=horsepower y=mpg_city;
run;&lt;/PRE&gt;
&lt;P&gt;You could use a DATTRMAP data set to assign colors/ line types if you add a / group=Make to series statement.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you have more than 2 or 3 levels for your actual data you may have to adjust the image size with an ODS Graphics statement setting height or width.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 06 May 2019 20:14:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556557#M18091</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2019-05-06T20:14:20Z</dc:date>
    </item>
    <item>
      <title>Re: how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556777#M18092</link>
      <description>&lt;P&gt;well, I prefer them separate than one panel. also. I need to show different models info within&amp;nbsp; a make.&lt;/P&gt;&lt;P&gt;if I have no choice, then I have to use proc sgpanel.&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2019 13:52:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556777#M18092</guid>
      <dc:creator>magicdj</dc:creator>
      <dc:date>2019-05-07T13:52:29Z</dc:date>
    </item>
    <item>
      <title>Re: how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556782#M18093</link>
      <description>&lt;P&gt;How do you want to represent the additional model info within each cell?&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2019 14:19:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556782#M18093</guid>
      <dc:creator>DanH_sas</dc:creator>
      <dc:date>2019-05-07T14:19:37Z</dc:date>
    </item>
    <item>
      <title>Re: how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556791#M18094</link>
      <description>&lt;P&gt;individual line plot, each make has different models, each model has a different line.&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2019 14:45:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556791#M18094</guid>
      <dc:creator>magicdj</dc:creator>
      <dc:date>2019-05-07T14:45:09Z</dc:date>
    </item>
    <item>
      <title>Re: how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556802#M18095</link>
      <description>&lt;P&gt;Using a variation of&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13884"&gt;@ballardw&lt;/a&gt;&amp;nbsp;'s program, and the layout you have in you GTL template, the code would look something like the following:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sort data=sashelp.cars
   out=work.cars;
   by make model horsepower;
run;


proc sgpanel data=work.cars;
  panelby make / columns=3 rows-2;
  series x=horsepower y=mpg_city / group=model;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;You can also using the SPACING option on the PANELBY statement to create space between the cells, which sounds like something you wanted. It is also possible to create a similar output using GTL using the DATAPANEL layout, but you can do it with less code using SGPANEL.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps!&lt;/P&gt;
&lt;P&gt;Dan&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2019 15:00:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556802#M18095</guid>
      <dc:creator>DanH_sas</dc:creator>
      <dc:date>2019-05-07T15:00:50Z</dc:date>
    </item>
    <item>
      <title>Re: how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556832#M18097</link>
      <description>&lt;P&gt;the problem is that different plots prefer to have different scale. sgpanel&amp;nbsp; only has fixed scale on left side, even using spacing option.&lt;/P&gt;&lt;P&gt;not each cell have it's own scale.&lt;/P&gt;&lt;P&gt;for GTL, I don't know how to use IF option. my code in first post is not working properly.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks for your help.&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2019 16:09:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556832#M18097</guid>
      <dc:creator>magicdj</dc:creator>
      <dc:date>2019-05-07T16:09:44Z</dc:date>
    </item>
    <item>
      <title>Re: how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556884#M18098</link>
      <description>&lt;P&gt;Ah, I didn't realize that independent scale per plot was an issue for you. In that case, neither SGPANEL nor DATAPANEL will works for you, The GTL "if" conditional logic will not work for you either, in this case. What version of SAS do you have? if SAS 9.4, which maintenance version?&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2019 17:17:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556884#M18098</guid>
      <dc:creator>DanH_sas</dc:creator>
      <dc:date>2019-05-07T17:17:11Z</dc:date>
    </item>
    <item>
      <title>Re: how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556885#M18099</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/224340"&gt;@magicdj&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;the problem is that different plots prefer to have different scale. sgpanel&amp;nbsp; only has fixed scale on left side, even using spacing option.&lt;/P&gt;
&lt;P&gt;not each cell have it's own scale.&lt;/P&gt;
&lt;P&gt;for GTL, I don't know how to use IF option. my code in first post is not working properly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thanks for your help.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;The PANELBY option UNISCALE sets which axes are identical. The default is all but if you use UNISCALE=COLUMN only the X axis will have the same scale within each row. So with a single column each panel would likely have a separate Y axis if the data required it.&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2019 17:19:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556885#M18099</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2019-05-07T17:19:27Z</dc:date>
    </item>
    <item>
      <title>Re: how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556891#M18100</link>
      <description>&lt;P&gt;I have 2&amp;nbsp;row and 2&amp;nbsp;column panel, so this option won't work for me.&lt;/P&gt;&lt;P&gt;I curious one thing. I have 2&amp;nbsp;row and 2&amp;nbsp;column format, if I have extra plot, for example 5 or 7 plots, it produced an empty cell in last row, anyone know how to get ride of empty cell? thanks a lot.&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2019 17:34:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556891#M18100</guid>
      <dc:creator>magicdj</dc:creator>
      <dc:date>2019-05-07T17:34:42Z</dc:date>
    </item>
    <item>
      <title>Re: how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556895#M18101</link>
      <description>&lt;P&gt;I got it, use skipemptycells to get ride of it.&lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://communities.sas.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2019 17:48:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/556895#M18101</guid>
      <dc:creator>magicdj</dc:creator>
      <dc:date>2019-05-07T17:48:58Z</dc:date>
    </item>
    <item>
      <title>Re: how to put multi plots in 1 rtf?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/557223#M18111</link>
      <description>&lt;P&gt;I use&amp;nbsp;SAS 9.4, have no idea about maintenance version and don't know where to check maintenance version&lt;/P&gt;</description>
      <pubDate>Wed, 08 May 2019 18:08:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/how-to-put-multi-plots-in-1-rtf/m-p/557223#M18111</guid>
      <dc:creator>magicdj</dc:creator>
      <dc:date>2019-05-08T18:08:56Z</dc:date>
    </item>
  </channel>
</rss>

