<?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: Format allignment in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664505#M198530</link>
    <description>That's exactly the point of my latter comment. It did for me, but won't for you and there's almost no way to guarantee that AFAIK unless you explicitly use annotate and control the location on the graphic. The way HTML renders by default makes this difficult. I'm not even sure annotate would get around this...you probably want to be generating SVG type graphics maybe instead? Or fixed images that can't scale?</description>
    <pubDate>Tue, 23 Jun 2020 22:22:48 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2020-06-23T22:22:48Z</dc:date>
    <item>
      <title>Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664466#M198507</link>
      <description>Hi. I have the following format.&lt;BR /&gt;Proc format;&lt;BR /&gt;Value&lt;BR /&gt;1=“kids reference”&lt;BR /&gt;2=“teenagers 4(3-6)”&lt;BR /&gt;3=“older 16(10-18)”&lt;BR /&gt;;&lt;BR /&gt;&lt;BR /&gt;How can I align by “-“ when print out. Thank you.</description>
      <pubDate>Tue, 23 Jun 2020 20:14:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664466#M198507</guid>
      <dc:creator>Emma8</dc:creator>
      <dc:date>2020-06-23T20:14:08Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664471#M198511</link>
      <description>&lt;P&gt;I don't think the forum is showing what you want. When typing out data that has a fixed structure try using a code block - 8th icon above the box you're typing in after hitting Reply (not Quick Reply).&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jun 2020 20:10:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664471#M198511</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-06-23T20:10:20Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664475#M198515</link>
      <description>&lt;P&gt;Considering that the posted Proc Format code will not run because it using "pretty" quotes instead of programming quotes...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You &lt;STRONG&gt;might &lt;/STRONG&gt;get close using code similar to:&lt;/P&gt;
&lt;PRE&gt;Proc format;
Value
1="kids reference"
2="teenagers 4 (3-6)"
3="older    16(10-18)"
;
&lt;/PRE&gt;
&lt;P&gt;But anything displaying these values with a proportional font (any thing not monospace like Courier or SAS Monospace) will likely have some difference of appearance as different letters take up different amounts of space and multiple spaces are almost always going to be significantly reduced.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You really need to show how/where you expect to use that format as well.&lt;/P&gt;
&lt;P&gt;As a quick reference to differences in propottional fonts.&lt;/P&gt;
&lt;P&gt;iiiiiiiiiiiiiii&lt;/P&gt;
&lt;P&gt;wwwwwwwwwwwwwww&lt;/P&gt;
&lt;P&gt;Those two lines above both contain 15 characters. I will bet a short stack of $$ that the row of i values is lots shorter than the w values.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jun 2020 20:21:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664475#M198515</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2020-06-23T20:21:37Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664483#M198519</link>
      <description>I did as you did but when I proc sgplot that variable it’s would not line up nicely as formatted by the “-“</description>
      <pubDate>Tue, 23 Jun 2020 20:39:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664483#M198519</guid>
      <dc:creator>Emma8</dc:creator>
      <dc:date>2020-06-23T20:39:46Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664484#M198520</link>
      <description>Can you provide a fully worked example then so we can test the code and solutions?</description>
      <pubDate>Tue, 23 Jun 2020 20:41:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664484#M198520</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-06-23T20:41:07Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664486#M198521</link>
      <description>Proc sgplot data...&lt;BR /&gt;Format Cc Ccformat.;&lt;BR /&gt;Run;</description>
      <pubDate>Tue, 23 Jun 2020 21:04:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664486#M198521</guid>
      <dc:creator>Emma8</dc:creator>
      <dc:date>2020-06-23T21:04:33Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664488#M198522</link>
      <description>&lt;P&gt;1) we need data&lt;/P&gt;
&lt;P&gt;2) we need the entire code to recreate your graph which means:&lt;/P&gt;
&lt;P&gt;3) we need to know the ODS destination and the ods style in affect when you generate the graph,&lt;/P&gt;
&lt;P&gt;and possibly 4) ods graphics options set.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And then describe where this is appearing that it should "align". In a legend? Axis? Axistable?&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jun 2020 21:16:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664488#M198522</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2020-06-23T21:16:24Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664496#M198525</link>
      <description>Thank you.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;data test;&lt;BR /&gt;set sashelp.class;&lt;BR /&gt;if age in (12,13) then gr=1;&lt;BR /&gt;else if age =14 then gr=2;&lt;BR /&gt;else gr=3;&lt;BR /&gt;run;&lt;BR /&gt;&lt;BR /&gt;proc sort data=test;&lt;BR /&gt;by gr;&lt;BR /&gt;run;&lt;BR /&gt;proc format;&lt;BR /&gt;value gr&lt;BR /&gt;1="kids        Reference"&lt;BR /&gt;2="teenagers        9 (4-24)"&lt;BR /&gt;3="old            78 (32-189)"&lt;BR /&gt;;&lt;BR /&gt;proc template;&lt;BR /&gt;   define style mystyle;&lt;BR /&gt;   parent=styles.sasweb;&lt;BR /&gt;      class graphwalls / &lt;BR /&gt;            frameborder=on;&lt;BR /&gt;      class graphbackground / &lt;BR /&gt;            color=white;&lt;BR /&gt;   end;&lt;BR /&gt;run;&lt;BR /&gt;ods graphics on / reset=all;&lt;BR /&gt;ods html style=mystyle path='.' file='newgraph.html';&lt;BR /&gt;ods graphics / reset=all  width=6.5in height=4.5in border=off ; &lt;BR /&gt;   legend1 label=none;&lt;BR /&gt;    proc sgplot data=test DATTRMAP=attrmap1;&lt;BR /&gt;      scatter x=weight y=Height /group=gr  ;&lt;BR /&gt; keylegend / location=outside position=bottom NOBORDER down=4;&lt;BR /&gt; label gr='Age, years       OR (95% CI)';&lt;BR /&gt; format gr gr.;&lt;BR /&gt;   run;</description>
      <pubDate>Tue, 23 Jun 2020 22:04:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664496#M198525</guid>
      <dc:creator>Emma8</dc:creator>
      <dc:date>2020-06-23T22:04:05Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664499#M198526</link>
      <description>&lt;P&gt;This worked for me:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc format;
value gr
1="kids Reference"
2="teenagers 9 (4-24)"
3="old          78(32-189)"
;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;That being said, HTML alignment is a tricky thing. If you have a different resolution shown on screen or a different zoom level I'm not sure you can fix that component. You may want to consider using a annotate option to add that information into your graph instead if positioning is super important.&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jun 2020 22:11:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664499#M198526</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-06-23T22:11:45Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664503#M198528</link>
      <description>Thanks. &lt;BR /&gt;But does not line up by “-“—does not produce what I wanted</description>
      <pubDate>Tue, 23 Jun 2020 22:18:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664503#M198528</guid>
      <dc:creator>Emma8</dc:creator>
      <dc:date>2020-06-23T22:18:56Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664504#M198529</link>
      <description>&lt;P&gt;Please post code into a code box opened with either the &amp;lt;/&amp;gt; or "running man" icon as in my example. The message windows&amp;nbsp;&lt;STRONG&gt;will&lt;/STRONG&gt; reformat code removing blanks. So any attempt at alignment in your proc format code has been removed.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And since you referenced yet another data set, the DATTRMAP set, to duplicate your exact results we would need that as well.&lt;/P&gt;
&lt;P&gt;Instructions here: &lt;A href="https://communities.sas.com/t5/SAS-Communities-Library/How-to-create-a-data-step-version-of-your-data-AKA-generate/ta-p/258712" target="_blank"&gt;https://communities.sas.com/t5/SAS-Communities-Library/How-to-create-a-data-step-version-of-your-data-AKA-generate/ta-p/258712&lt;/A&gt; will show how to turn an existing SAS data set into data step code that can be pasted into a forum code box using the &amp;lt;/&amp;gt; icon or attached as text to show exactly what you have and that we can test code against.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jun 2020 22:19:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664504#M198529</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2020-06-23T22:19:42Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664505#M198530</link>
      <description>That's exactly the point of my latter comment. It did for me, but won't for you and there's almost no way to guarantee that AFAIK unless you explicitly use annotate and control the location on the graphic. The way HTML renders by default makes this difficult. I'm not even sure annotate would get around this...you probably want to be generating SVG type graphics maybe instead? Or fixed images that can't scale?</description>
      <pubDate>Tue, 23 Jun 2020 22:22:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664505#M198530</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-06-23T22:22:48Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664508#M198533</link>
      <description>Don’t know. It generates html graph. How can I annotate?</description>
      <pubDate>Tue, 23 Jun 2020 22:31:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664508#M198533</guid>
      <dc:creator>Emma8</dc:creator>
      <dc:date>2020-06-23T22:31:02Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664510#M198535</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/294547"&gt;@Emma8&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;Thanks. &lt;BR /&gt;But does not line up by “-“—does not produce what I wanted&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Did you read the bit I posted about the i's and w's? That is what is going on here. Spaces take up less area than most characters with a proportional font.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can try adding more spaces in the format and things may get close but exact alignment is very likely a hit and miss(mostly) proposition. However as soon as you get this to sort of work with one set of options then the next time you do this and have a different measure and interval to display the trial and error begins again.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You might consider moving to GTL and have second graph that shows a forest plot of the OR and CI values (for the groups with such) under the scatterplot. Which may provide a better feel for the data than the few digits displayed.&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jun 2020 22:36:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664510#M198535</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2020-06-23T22:36:25Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664511#M198536</link>
      <description>Thanks. &lt;BR /&gt;I just want to line up by this symbol “-“</description>
      <pubDate>Tue, 23 Jun 2020 22:40:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664511#M198536</guid>
      <dc:creator>Emma8</dc:creator>
      <dc:date>2020-06-23T22:40:20Z</dc:date>
    </item>
    <item>
      <title>Re: Format allignment</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664543#M198551</link>
      <description>&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;data test;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;set sashelp.class;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;if age in (12,13) then gr=1;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;else if age =14 then gr=2;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;else gr=3;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;run;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;proc sort data=test;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;by gr;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;run;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;proc format;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;value gr&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;1="kids Reference"&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;2="teenagers 9 (4-24)"&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;3="old 78 (32-189)"&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;proc template;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;define style mystyle;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;parent=styles.sasweb;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;class graphwalls /&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;frameborder=on;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;class graphbackground /&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;color=white;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;end;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;run;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;ods graphics on / reset=all;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;ods html style=mystyle path='.' file='newgraph.html';&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;ods graphics / reset=all width=6.5in height=4.5in border=off ;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;legend1 label=none;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;proc sgplot data=test DATTRMAP=attrmap1;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;scatter x=weight y=Height /group=gr ;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;keylegend / location=outside position=bottom NOBORDER down=4;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;label gr='Age, years OR (95% CI)';&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;format gr gr.;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;SPAN&gt;run;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;The least you can do is:&lt;/P&gt;
&lt;P&gt;1. Please format the code you post&lt;/P&gt;
&lt;P&gt;2. Please run the code you post; This code results in an error.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also:&lt;/P&gt;
&lt;P&gt;3.The only way to align text in the manner you want is to use fixed-pitch font, as you have been told.&lt;/P&gt;
&lt;P&gt;Do you understand this?&lt;/P&gt;
&lt;P&gt;4. If you do, you can see why this aligns the legend as you request:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc format;
  value gr
  1="kids Reference"
  2="teenagers 9 (4-24)"
  3="old 78     (32-189)"
;
...
proc sgplot data=TEST;
...
keylegend / ...  valueattrs=(family='Courier New') ;
...
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;DIV id="tinyMceEditorChrisNZ_0" class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;P&gt;Here is the image (broken on some browsers it seems):&lt;/P&gt;
&lt;DIV id="tinyMceEditorChrisNZ_4" class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="tinyMceEditorChrisNZ_5" class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="tinyMceEditorChrisNZ_6" class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="tinyMceEditorChrisNZ_7" class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/46562i0820DB41264C9397/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt; &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 24 Jun 2020 04:49:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Format-allignment/m-p/664543#M198551</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2020-06-24T04:49:40Z</dc:date>
    </item>
  </channel>
</rss>

