<?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: Proc SGPanel with bars having a background color in Graphics Programming</title>
    <link>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23673#M660</link>
    <description>Thanks Dan&lt;BR /&gt;
&lt;BR /&gt;
Appreciate your help.&lt;BR /&gt;
&lt;BR /&gt;
Siri</description>
    <pubDate>Tue, 08 Mar 2011 21:44:57 GMT</pubDate>
    <dc:creator>Siri29</dc:creator>
    <dc:date>2011-03-08T21:44:57Z</dc:date>
    <item>
      <title>Proc SGPanel with bars having a background color</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23666#M653</link>
      <description>Hello SAS Forum.&lt;BR /&gt;
&lt;BR /&gt;
Is there any way ,I could set a background color for the bars while using the proc sgpanel.&lt;BR /&gt;
&lt;BR /&gt;
Here is the sample code for panels(with bars).I want to set a background for bars.&lt;BR /&gt;
/***************************************************************************************&lt;BR /&gt;
&lt;BR /&gt;
title1 "Average MPG (City) by Vehicle Origin and Type";&lt;BR /&gt;
&lt;BR /&gt;
 proc sgpanel data = sashelp.cars ;&lt;BR /&gt;
&lt;BR /&gt;
  panelby origin / layout=columnlattice  onepanel novarname  &lt;BR /&gt;
&lt;BR /&gt;
                   noborder  colheaderpos=top;&lt;BR /&gt;
&lt;BR /&gt;
  hbar type / response=mpg_city group=type  ;&lt;BR /&gt;
&lt;BR /&gt;
  colaxis display=none  ;&lt;BR /&gt;
&lt;BR /&gt;
  rowaxis label="Average MPG (City)" ;&lt;BR /&gt;
&lt;BR /&gt;
  keylegend / title="Type" position=right across=1  ;&lt;BR /&gt;
&lt;BR /&gt;
run;&lt;BR /&gt;
************************************************************************************/&lt;BR /&gt;
&lt;BR /&gt;
Any idea on this??&lt;BR /&gt;
&lt;BR /&gt;
Please let me know..&lt;BR /&gt;
&lt;BR /&gt;
Appreciate your help.&lt;BR /&gt;
&lt;BR /&gt;
Thanks&lt;BR /&gt;
&lt;BR /&gt;
Siri</description>
      <pubDate>Mon, 07 Mar 2011 18:56:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23666#M653</guid>
      <dc:creator>Siri29</dc:creator>
      <dc:date>2011-03-07T18:56:24Z</dc:date>
    </item>
    <item>
      <title>Re: Proc SGPanel with bars having a background color</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23667#M654</link>
      <description>You can do it by changing the wall color in the style. You can make a little style that inherits from your favorite style but just changes the wall color. Here is a little example:&lt;BR /&gt;
&lt;BR /&gt;
[pre]&lt;BR /&gt;
proc template;&lt;BR /&gt;
define style styles.mybackground;&lt;BR /&gt;
parent=styles.listing; /* or your favorite style */&lt;BR /&gt;
style graphwalls from graphwalls /&lt;BR /&gt;
   color=yellow;&lt;BR /&gt;
end;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
ods listing style=mybackground; &lt;BR /&gt;
[/pre]&lt;BR /&gt;
&lt;BR /&gt;
Hope this helps,&lt;BR /&gt;
Dan</description>
      <pubDate>Mon, 07 Mar 2011 19:17:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23667#M654</guid>
      <dc:creator>DanH_sas</dc:creator>
      <dc:date>2011-03-07T19:17:52Z</dc:date>
    </item>
    <item>
      <title>Re: Proc SGPanel with bars having a background color</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23668#M655</link>
      <description>Thanks Dan for your quick response.&lt;BR /&gt;
&lt;BR /&gt;
But somehow I couldn't get the background .&lt;BR /&gt;
&lt;BR /&gt;
this is the way I proceeded:&lt;BR /&gt;
&lt;BR /&gt;
/**************************************************************&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
proc template;&lt;BR /&gt;
define style styles.mybackground;&lt;BR /&gt;
parent=styles.listing; /* or your favorite style */&lt;BR /&gt;
style graphwalls from graphwalls /&lt;BR /&gt;
color=yellow;&lt;BR /&gt;
end;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
ods listing file =  "mybackground" ;&lt;BR /&gt;
&lt;BR /&gt;
title1 "Average MPG (City) by Vehicle Origin and Type";&lt;BR /&gt;
proc sgpanel data = sashelp.cars   description= "mybackground";  &lt;BR /&gt;
  panelby origin / layout=columnlattice  onepanel novarname   &lt;BR /&gt;
&lt;BR /&gt;
                   noborder  colheaderpos=top ;&lt;BR /&gt;
&lt;BR /&gt;
  hbar type / response=mpg_city group=type        ;&lt;BR /&gt;
&lt;BR /&gt;
  colaxis display=none  ;&lt;BR /&gt;
&lt;BR /&gt;
  rowaxis label="Average MPG (City)" ;&lt;BR /&gt;
&lt;BR /&gt;
  keylegend / title="Type" position=right across=1    ;&lt;BR /&gt;
&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
/******************************************************************&lt;BR /&gt;
&lt;BR /&gt;
Its giving me a warning:&lt;BR /&gt;
&lt;BR /&gt;
WARNING: Unsupported device 'ACTIVEX' for LISTING destination. Using device 'ACTXIMG'.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
I get the output but not with the background for bars.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Thanks again for your help.&lt;BR /&gt;
&lt;BR /&gt;
Siri</description>
      <pubDate>Mon, 07 Mar 2011 19:49:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23668#M655</guid>
      <dc:creator>Siri29</dc:creator>
      <dc:date>2011-03-07T19:49:47Z</dc:date>
    </item>
    <item>
      <title>Re: Proc SGPanel with bars having a background color</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23669#M656</link>
      <description>The ODS LISTING statement should read: &lt;BR /&gt;
&lt;BR /&gt;
ods listing style=mybackground;&lt;BR /&gt;
&lt;BR /&gt;
Your example had: &lt;BR /&gt;
&lt;BR /&gt;
ods listing file="mybackground";&lt;BR /&gt;
&lt;BR /&gt;
Give that a try and see if that works for you.&lt;BR /&gt;
&lt;BR /&gt;
Thanks!&lt;BR /&gt;
Dan</description>
      <pubDate>Mon, 07 Mar 2011 19:58:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23669#M656</guid>
      <dc:creator>DanH_sas</dc:creator>
      <dc:date>2011-03-07T19:58:27Z</dc:date>
    </item>
    <item>
      <title>Re: Proc SGPanel with bars having a background color</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23670#M657</link>
      <description>Thanks Dan&lt;BR /&gt;
&lt;BR /&gt;
I did change it...&lt;BR /&gt;
&lt;BR /&gt;
Its giving me output without any errors,but not with the background&lt;BR /&gt;
&lt;BR /&gt;
here is what i have done.&lt;BR /&gt;
/************************************************************************&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
proc template;&lt;BR /&gt;
define style styles.mybackground;&lt;BR /&gt;
parent=styles.listing; /* or your favorite style */&lt;BR /&gt;
style graphwalls from graphwalls /&lt;BR /&gt;
color=yellow;&lt;BR /&gt;
end;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
ods listing style =  mybackground ;&lt;BR /&gt;
&lt;BR /&gt;
title1 "Average MPG (City) by Vehicle Origin and Type";&lt;BR /&gt;
proc sgpanel data = sashelp.cars   description= "mybackground";  &lt;BR /&gt;
  panelby origin / layout=columnlattice  onepanel novarname   &lt;BR /&gt;
&lt;BR /&gt;
                   noborder  colheaderpos=top ;&lt;BR /&gt;
&lt;BR /&gt;
  hbar type / response=mpg_city group=type        ;&lt;BR /&gt;
&lt;BR /&gt;
  colaxis display=none  ;&lt;BR /&gt;
&lt;BR /&gt;
  rowaxis label="Average MPG (City)" ;&lt;BR /&gt;
&lt;BR /&gt;
  keylegend / title="Type" position=right across=1    ;&lt;BR /&gt;
&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
/***********************************************************************&lt;BR /&gt;
&lt;BR /&gt;
Am I calling the template correctly in the Panel block?&lt;BR /&gt;
&lt;BR /&gt;
Thanks&lt;BR /&gt;
&lt;BR /&gt;
Sri</description>
      <pubDate>Mon, 07 Mar 2011 20:05:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23670#M657</guid>
      <dc:creator>Siri29</dc:creator>
      <dc:date>2011-03-07T20:05:27Z</dc:date>
    </item>
    <item>
      <title>Re: Proc SGPanel with bars having a background color</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23671#M658</link>
      <description>Hey Siri,&lt;BR /&gt;
&lt;BR /&gt;
Your code runs correctly for me. Try restarting your SAS session and see if that helps. Your session may be in a state where the style request is getting ignored. Let me know if that works for you.&lt;BR /&gt;
&lt;BR /&gt;
Thanks!&lt;BR /&gt;
Dan</description>
      <pubDate>Mon, 07 Mar 2011 20:27:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23671#M658</guid>
      <dc:creator>DanH_sas</dc:creator>
      <dc:date>2011-03-07T20:27:52Z</dc:date>
    </item>
    <item>
      <title>Re: Proc SGPanel with bars having a background color</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23672#M659</link>
      <description>Hey Dan&lt;BR /&gt;
&lt;BR /&gt;
Its the same problem again...&lt;BR /&gt;
No background&lt;BR /&gt;
&lt;BR /&gt;
Siri</description>
      <pubDate>Mon, 07 Mar 2011 20:38:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23672#M659</guid>
      <dc:creator>Siri29</dc:creator>
      <dc:date>2011-03-07T20:38:34Z</dc:date>
    </item>
    <item>
      <title>Re: Proc SGPanel with bars having a background color</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23673#M660</link>
      <description>Thanks Dan&lt;BR /&gt;
&lt;BR /&gt;
Appreciate your help.&lt;BR /&gt;
&lt;BR /&gt;
Siri</description>
      <pubDate>Tue, 08 Mar 2011 21:44:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-SGPanel-with-bars-having-a-background-color/m-p/23673#M660</guid>
      <dc:creator>Siri29</dc:creator>
      <dc:date>2011-03-08T21:44:57Z</dc:date>
    </item>
  </channel>
</rss>

