<?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 I add multiple variables title to histograms in proc univariate in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634512#M188318</link>
    <description>&lt;P&gt;I am not sure exactly what you want for the title but you can use the \l to use the label of a variable as part of the title. If you don't provide any other string then the variable label is all that would appear.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;ods graphics on;
proc univariate data=sashelp.class ;
   var age height weight;
   histogram / normal odstitle='\l';
	label age ='Age at enrollment'
	      height= 'Height at graduation'
	      weight= 'Weight at lunch'
	;
run;
title;
ods graphics off;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;If you want the same text to appear at the end of the "title" then use &lt;/P&gt;
&lt;P&gt;odstitle ='\l for 2015 Fords'&lt;/P&gt;</description>
    <pubDate>Tue, 24 Mar 2020 17:38:26 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2020-03-24T17:38:26Z</dc:date>
    <item>
      <title>How to I add multiple variables title to histograms in proc univariate</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634486#M188312</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Trying to figure out how do I add titles to my 3 variables?&lt;/P&gt;&lt;P&gt;Below is my code:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;ods graphics on;&lt;BR /&gt;proc univariate data=ford_2015 plot;&lt;BR /&gt;	var city08 fuelcost08 displ;&lt;BR /&gt;	histogram / normal odstitle = "City MPG for 2015 Fords"&lt;BR /&gt;	"Annual Fuel cost for 2015 Fords""Engine Displacement in ltrs for 2015 Fords";&lt;BR /&gt;	label city08 = "City MPG";&lt;BR /&gt;	label fuelcost08 ="Annual Fuel cost";&lt;BR /&gt;	label  displ="Displacement in ltrs";&lt;BR /&gt;run;&lt;/PRE&gt;&lt;P&gt;upon running this code I get the following error:&lt;/P&gt;&lt;DIV class="sasSource"&gt;histogram / normal odstitle = "City MPG for 2015 Fords"&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;78 "Annual Fuel cost for 2015 Fords""Engine Displacement in ltrs for 2015 Fords";&lt;/DIV&gt;&lt;DIV class="sasError"&gt;_____________________________________________________________________________&lt;/DIV&gt;&lt;DIV class="sasError"&gt;22&lt;/DIV&gt;&lt;DIV class="sasError"&gt;200&lt;/DIV&gt;&lt;DIV class="sasError"&gt;ERROR 22-322: Syntax error, expecting one of the following: ;, ANNOKEY, ANNOTATE, BARFILL, BARLABEL, BARWIDTH, BETA, CAXIS,&lt;/DIV&gt;&lt;DIV class="sasError"&gt;CBARLINE, CFILL, CFRAME, CFRAMESIDE, CFRAMETOP, CGRID, CHREF, CLIPCURVES, CLIPREF, CONTENTS, CPROP, CSTATREF, CTEXT,&lt;/DIV&gt;&lt;DIV class="sasError"&gt;CV, CVREF, DESCRIPTION, ENDPOINTS, EXPONENTIAL, FONT, FRONTREF, GAMMA, GRID, GUMBEL, HANGING, HAXIS, HEIGHT, HMINOR,&lt;/DIV&gt;&lt;DIV class="sasError"&gt;HOFFSET, HREF, HREFLABELS, HREFLABPOS, IGAUSS, INFONT, INHEIGHT, INTERBAR, INTERTILE, KERNEL, LGRID, LHREF,&lt;/DIV&gt;&lt;DIV class="sasError"&gt;LOGNORMAL, LSTATREF, LVREF, MAXNBIN, MAXSIGMAS, MIDPERCENTS, MIDPOINTS, NAME, NCOL, NCOLS, NENDPOINTS, NMIDPOINTS,&lt;/DIV&gt;&lt;DIV class="sasError"&gt;NOBARS, NOCHART, NOCURVELEGEND, NOFRAME, NOHLABEL, NOLEGEND, NOPLOT, NORMAL, NOTABCONTENTS, NOVLABEL, NOVTICK, NROW,&lt;/DIV&gt;&lt;DIV class="sasError"&gt;NROWS, ODSFOOTNOTE, ODSFOOTNOTE2, ODSTITLE, ODSTITLE2, OUTHISTOGRAM, OUTKERNEL, OVERLAY, PARETO, PFILL, POWER,&lt;/DIV&gt;&lt;DIV class="sasError"&gt;RAYLEIGH, RTINCLUDE, SB, STATREF, STATREFLABELS, STATREFSUBCHAR, SU, TILELEGLABEL, TURNVLABELS, VAXIS, VAXISLABEL,&lt;/DIV&gt;&lt;DIV class="sasError"&gt;VMINOR, VOFFSET, VREF, VREFLABELS, VREFLABPOS, VSCALE, WAXIS, WBARLINE, WEIBULL, WGRID, WHREF, WSTATREF, WVREF.&lt;/DIV&gt;&lt;DIV class="sasError"&gt;ERROR 200-322: The symbol is not recognized and will be ignored.&lt;/DIV&gt;</description>
      <pubDate>Tue, 24 Mar 2020 16:53:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634486#M188312</guid>
      <dc:creator>vedaj16</dc:creator>
      <dc:date>2020-03-24T16:53:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to I add multiple variables title to histograms in proc univariate</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634512#M188318</link>
      <description>&lt;P&gt;I am not sure exactly what you want for the title but you can use the \l to use the label of a variable as part of the title. If you don't provide any other string then the variable label is all that would appear.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;ods graphics on;
proc univariate data=sashelp.class ;
   var age height weight;
   histogram / normal odstitle='\l';
	label age ='Age at enrollment'
	      height= 'Height at graduation'
	      weight= 'Weight at lunch'
	;
run;
title;
ods graphics off;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;If you want the same text to appear at the end of the "title" then use &lt;/P&gt;
&lt;P&gt;odstitle ='\l for 2015 Fords'&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2020 17:38:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634512#M188318</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2020-03-24T17:38:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to I add multiple variables title to histograms in proc univariate</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634518#M188322</link>
      <description>&lt;P&gt;Put your data into long format and use by-processing with #byval substitution in the title. Example:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data graph;
set sashelp.cars;
where make = "Ford";
value = EngineSize; parameter = "Engine Size"; output;
value = HorsePower; parameter = "Horse Power"; output;
value = Length; parameter = "Length"; output;
keep type parameter value;
run;

proc sort data=graph; by parameter; run;

title2 "Parameter = #BYVAL1";
proc univariate data=graph;
var value;
by parameter;
histogram / normal odstitle = "Ford Models" odstitle2=title2;
run;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 24 Mar 2020 17:52:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634518#M188322</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2020-03-24T17:52:22Z</dc:date>
    </item>
    <item>
      <title>Re: How to I add multiple variables title to histograms in proc univariate</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634531#M188328</link>
      <description>It worked! Thanks a lot!&lt;BR /&gt;</description>
      <pubDate>Tue, 24 Mar 2020 18:43:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634531#M188328</guid>
      <dc:creator>vedaj16</dc:creator>
      <dc:date>2020-03-24T18:43:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to I add multiple variables title to histograms in proc univariate</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634532#M188329</link>
      <description>Thanks for your solution. I will keep this format for sure!</description>
      <pubDate>Tue, 24 Mar 2020 18:44:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634532#M188329</guid>
      <dc:creator>vedaj16</dc:creator>
      <dc:date>2020-03-24T18:44:01Z</dc:date>
    </item>
    <item>
      <title>Re: How to I add multiple variables title to histograms in proc univariate</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634700#M188402</link>
      <description>&lt;P&gt;Try using multiple HISTOGRAM statement ?&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc univariate data=sashelp.class ;
   var age height weight;
   histogram age/ normal odstitle='age';
   histogram height/ normal odstitle='height';
   histogram weight/ normal odstitle='weight';
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 25 Mar 2020 11:38:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-I-add-multiple-variables-title-to-histograms-in-proc/m-p/634700#M188402</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2020-03-25T11:38:44Z</dc:date>
    </item>
  </channel>
</rss>

