<?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 create a formatted unicode character within a GTL label in Graphics Programming</title>
    <link>https://communities.sas.com/t5/Graphics-Programming/How-to-create-a-formatted-unicode-character-within-a-GTL-label/m-p/499971#M17044</link>
    <description>&lt;P&gt;Hi there!&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for your reply. The challenge is italicizing theta without italicizing "P("&amp;nbsp; and ")". Apparently it cannot be done.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I received a reply from tech support, pasted below:&lt;/P&gt;
&lt;P&gt;---------------------------------------------------------------------------------------------------------------------------&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Garnett,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;There is not an option to italicize only a portion of an axis label. &amp;nbsp;The text style applies to the entire label.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;You can use a DRAWTEXT statement to place the text on the graph to simulate the label.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Below is a simple sample that will suppress the default Y axis label and use the DRAWTEXT statement to place text to the left of the graph. &amp;nbsp;The PAD= option on the BEGINGRAPH statement adds space to the left of the graph where we want the text to be placed. &amp;nbsp;You might need to adjust the PAD= value, depending on how the text looks on your graph. &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc template;

&amp;nbsp; define statgraph plot;

&amp;nbsp; &amp;nbsp;&amp;nbsp;begingraph / pad=( left=5%);

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;layout overlay / yaxisopts=(display=(ticks tickvalues line));

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;scatterplot x=age y=height;

&amp;nbsp;

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;drawtext textattrs=(style=normal) "P" textattrs=(style=italic) "(*ESC*){unicode theta}" / xspace=graphpercent yspace=wallpercent x=2 y=50

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;rotate=90 anchor=center width=50;

&amp;nbsp;

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;endlayout;

&amp;nbsp;&amp;nbsp;&amp;nbsp;endgraph;

&amp;nbsp; end;

run;

proc sgrender data=sashelp.class template=plot;

run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 28 Sep 2018 17:01:30 GMT</pubDate>
    <dc:creator>Garnett</dc:creator>
    <dc:date>2018-09-28T17:01:30Z</dc:date>
    <item>
      <title>How to create a formatted unicode character within a GTL label</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-to-create-a-formatted-unicode-character-within-a-GTL-label/m-p/498531#M17007</link>
      <description>&lt;P&gt;Greetings!&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I can write within PROC TEMPLATE:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;layout overlay / yaxisopts=(label = "p((*ESC*){unicode theta})") ;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;I'd like the symbol theta (and only theta) to appear in italics. How can I do this? v9.4&lt;/P&gt;
&lt;P&gt;Thanks very much in advance!&lt;/P&gt;
&lt;P&gt;Garnett&lt;/P&gt;</description>
      <pubDate>Mon, 24 Sep 2018 19:20:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-to-create-a-formatted-unicode-character-within-a-GTL-label/m-p/498531#M17007</guid>
      <dc:creator>Garnett</dc:creator>
      <dc:date>2018-09-24T19:20:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a formatted unicode character within a GTL label</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-to-create-a-formatted-unicode-character-within-a-GTL-label/m-p/499898#M17040</link>
      <description>&lt;P&gt;Give this a try:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;layout overlay / 
   yaxisopts=(label = "(*ESC*){unicode theta}" labelattrs=(style=italic size=12pt));&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;To make it bold, add weight=bold to labelattrs=.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Sep 2018 13:43:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-to-create-a-formatted-unicode-character-within-a-GTL-label/m-p/499898#M17040</guid>
      <dc:creator>sdengland</dc:creator>
      <dc:date>2018-09-28T13:43:44Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a formatted unicode character within a GTL label</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-to-create-a-formatted-unicode-character-within-a-GTL-label/m-p/499971#M17044</link>
      <description>&lt;P&gt;Hi there!&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for your reply. The challenge is italicizing theta without italicizing "P("&amp;nbsp; and ")". Apparently it cannot be done.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I received a reply from tech support, pasted below:&lt;/P&gt;
&lt;P&gt;---------------------------------------------------------------------------------------------------------------------------&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Garnett,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;There is not an option to italicize only a portion of an axis label. &amp;nbsp;The text style applies to the entire label.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;You can use a DRAWTEXT statement to place the text on the graph to simulate the label.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Below is a simple sample that will suppress the default Y axis label and use the DRAWTEXT statement to place text to the left of the graph. &amp;nbsp;The PAD= option on the BEGINGRAPH statement adds space to the left of the graph where we want the text to be placed. &amp;nbsp;You might need to adjust the PAD= value, depending on how the text looks on your graph. &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc template;

&amp;nbsp; define statgraph plot;

&amp;nbsp; &amp;nbsp;&amp;nbsp;begingraph / pad=( left=5%);

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;layout overlay / yaxisopts=(display=(ticks tickvalues line));

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;scatterplot x=age y=height;

&amp;nbsp;

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;drawtext textattrs=(style=normal) "P" textattrs=(style=italic) "(*ESC*){unicode theta}" / xspace=graphpercent yspace=wallpercent x=2 y=50

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;rotate=90 anchor=center width=50;

&amp;nbsp;

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;endlayout;

&amp;nbsp;&amp;nbsp;&amp;nbsp;endgraph;

&amp;nbsp; end;

run;

proc sgrender data=sashelp.class template=plot;

run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Sep 2018 17:01:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-to-create-a-formatted-unicode-character-within-a-GTL-label/m-p/499971#M17044</guid>
      <dc:creator>Garnett</dc:creator>
      <dc:date>2018-09-28T17:01:30Z</dc:date>
    </item>
  </channel>
</rss>

