<?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: Subscript in axis label for SGPLOT showing as boxes in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Subscript-in-axis-label-for-SGPLOT-showing-as-boxes/m-p/823505#M325158</link>
    <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;
ods graphics/width=800px height=600px ;
proc sgplot data=sashelp.class;
  xaxis label= "Day of Positive Blood Smear";
yaxis label= "Day 1 Anti-CSP IgG Reactivity (Baseline-adjusted OD(*ESC*){unicode '2084'x}(*ESC*){unicode '2081'x}(*ESC*){unicode '2080'x})" 
labelattrs= GraphUnicodeText
labelattrs=(size=20);

   scatter x=weight y=height / group=sex;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Ksharp_0-1657892557826.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/73345iB87E49210929F83D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Ksharp_0-1657892557826.png" alt="Ksharp_0-1657892557826.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 15 Jul 2022 13:42:39 GMT</pubDate>
    <dc:creator>Ksharp</dc:creator>
    <dc:date>2022-07-15T13:42:39Z</dc:date>
    <item>
      <title>Subscript in axis label for SGPLOT showing as boxes</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Subscript-in-axis-label-for-SGPLOT-showing-as-boxes/m-p/823400#M325106</link>
      <description>&lt;P&gt;I am trying to get 410 to subscript in the y-axis label. As written below, I end up with a label looking like this:&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mariko5797_0-1657825635690.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/73324i8BCD9F67404DDCF2/image-size/medium?v=v2&amp;amp;px=400" role="button" title="mariko5797_0-1657825635690.png" alt="mariko5797_0-1657825635690.png" /&gt;&lt;/span&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;With labelattrs= GraphUnicodeText, I can get my subscript, but I lose my font style. How can I get the y-axis label to show the subscript while maintaining the font specified in proc template?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ods escapechar= '^';
proc template;
	  define style styles.myjournal2;                                              
      		parent=styles.journal;
      		style GraphBar from GraphComponent/displayopts="fill outline ";                                 
			style GraphDataText from GraphDataText/font=('Times New Roman', 9pt);

			class GraphFonts
				"Fonts used in graph styles" /
				'GraphValueFont' = ("&amp;lt;MTserif&amp;gt;, Times New Roman", 10pt)
				'GraphLabelFont' = ("&amp;lt;MTserif&amp;gt;, Times New Roman", 10pt)
				'GraphAnnoFont' = ("&amp;lt;MTserif&amp;gt;, Times New Roman", 10pt);
			class GraphWalls / frameborder = off;
  	  end;
run;

ods listing gpath= "&amp;lt;pathway&amp;gt;" style= styles.myjournal2;
ods graphics / reset= index attrpriority= none noborder imagename= "Fig_immuno_corr_smear" imagefmt= png;

proc sgplot data= _work_;
 styleattrs datacolors= (blue gold gray lightred)
			datacontrastcolors= (blue gold gray lightred)
 			datasymbols= (asterisk circle plus star)
			datalinepatterns= (solid mediumdash dashdotdot shortdashdot);
 reg y= igg x= phady / group= aphase clm clmtransparency= 0.9 jitter;
 	xaxis label= "Day of Positive Blood Smear";
	yaxis label= "Day 1 Anti-CSP IgG Reactivity (Baseline-adjusted OD^{unicode '2084'x}^{unicode '2081'x}^{unicode '2080'x})" /*labelattrs= GraphUnicodeText*/;

	legenditem type= markerline name= "_1" / label= "Dose 1" lineattrs= (pattern= solid color= blue) markerattrs= (symbol= asterisk color= blue);
	legenditem type= markerline name= "_2" / label= "Dose 2" lineattrs= (pattern= mediumdash color= gold) markerattrs= (symbol= circle color= gold);
	legenditem type= markerline name= "_3" / label= "Dose 3" lineattrs= (pattern= dashdotdot color= gray) markerattrs= (symbol= plus color= gray);
	legenditem type= markerline name= "_4" / label= "Dose 4" lineattrs= (pattern= shortdashdot color= lightred) markerattrs= (symbol= star color= lightred);
	keylegend "_1" "_2" "_3" "_4" / title= "Dose" noborder;
run;

ods _all_ close;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jul 2022 19:10:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Subscript-in-axis-label-for-SGPLOT-showing-as-boxes/m-p/823400#M325106</guid>
      <dc:creator>mariko5797</dc:creator>
      <dc:date>2022-07-14T19:10:14Z</dc:date>
    </item>
    <item>
      <title>Re: Subscript in axis label for SGPLOT showing as boxes</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Subscript-in-axis-label-for-SGPLOT-showing-as-boxes/m-p/823505#M325158</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;
ods graphics/width=800px height=600px ;
proc sgplot data=sashelp.class;
  xaxis label= "Day of Positive Blood Smear";
yaxis label= "Day 1 Anti-CSP IgG Reactivity (Baseline-adjusted OD(*ESC*){unicode '2084'x}(*ESC*){unicode '2081'x}(*ESC*){unicode '2080'x})" 
labelattrs= GraphUnicodeText
labelattrs=(size=20);

   scatter x=weight y=height / group=sex;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Ksharp_0-1657892557826.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/73345iB87E49210929F83D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Ksharp_0-1657892557826.png" alt="Ksharp_0-1657892557826.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jul 2022 13:42:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Subscript-in-axis-label-for-SGPLOT-showing-as-boxes/m-p/823505#M325158</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2022-07-15T13:42:39Z</dc:date>
    </item>
  </channel>
</rss>

