<?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 Can I Assign a Custom Color set to Gchart lines? in Graphics Programming</title>
    <link>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272708#M9731</link>
    <description>&lt;P&gt;According to:&lt;/P&gt;&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/grstatproc/67909/HTML/default/viewer.htm#p1dt33l6a6epk6n1chtynsgsjgit.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/grstatproc/67909/HTML/default/viewer.htm#p1dt33l6a6epk6n1chtynsgsjgit.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I need group = panelBy3 for colors to show up here? &amp;nbsp;Can I have the same first color without the group?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;data test2;                                                                                                                             

  set sashelp.workers;                                                                                                                  

  if electric &amp;gt; 270 then grouping =1;                                                                                                   

  else if electric &amp;gt; 255 then grouping =2;                                                                                              

  else grouping =3;                                                                                                                     

  if electric &amp;gt; 270 then panelBy1 =1;                                                                                                   

  else if electric &amp;gt; 255 then panelBy1 =2;                                                                                              

  else panelBy1 =3;   

  if electric &amp;gt; 270 then panelBy2 =1;                                                                                                   

  else if electric &amp;gt; 255 then panelBy2 =2;                                                                                              

  else panelBy2 =3; 

  if electric &amp;gt; 270 then panelBy3 =1;                                                                                                   

  else if electric &amp;gt; 255 then panelBy3 =2;                                                                                              

  else panelBy3 =3; 

run; 

proc sgpanel data=test2 ;
	panelby panelBy1 panelBy2 / layout=lattice uniscale=column novarname columns=4 onepanel headerbackcolor="969491" HEADERATTRS=(Weight=Bold color=white);
	styleattrs datacontrastcolors=(CXFFBA00 black CX969491 CX6341 CX63513D CX768692 CX69B3E7 CX6BCABA CXC6AA76 CXE9DF97 CXC4D600 CXE57200) 
	datacolors=(CXFFBA00 black CX969491 CX6341 CX63513D CX768692 CX69B3E7 CX6BCABA CXC6AA76 CXE9DF97 CXC4D600 CXE57200);
	vbar grouping / response=electric nostatlabel grouporder=ascending group = panelBy3;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;for a single color use:&amp;nbsp;&lt;SPAN&gt;vbar grouping / response=electric nostatlabel fillattrs=(color=CXFFBA00);&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 26 May 2016 12:52:29 GMT</pubDate>
    <dc:creator>DavidPhillips2</dc:creator>
    <dc:date>2016-05-26T12:52:29Z</dc:date>
    <item>
      <title>How Can I Assign a Custom Color set to Gchart lines?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272436#M9714</link>
      <description>&lt;P&gt;How can I assign a custom color set to gchart lines?&amp;nbsp; I’m using indexes with proc template. &amp;nbsp;(Using Enterprise Gude.)&lt;/P&gt;</description>
      <pubDate>Mon, 23 May 2016 15:17:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272436#M9714</guid>
      <dc:creator>DavidPhillips2</dc:creator>
      <dc:date>2016-05-23T15:17:49Z</dc:date>
    </item>
    <item>
      <title>Re: How Can I Assign a Custom Color set to Gchart lines?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272437#M9715</link>
      <description>&lt;P&gt;Are you talking about gchart outlines? Can you send a code snippit?&lt;/P&gt;</description>
      <pubDate>Mon, 23 May 2016 15:21:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272437#M9715</guid>
      <dc:creator>DanH_sas</dc:creator>
      <dc:date>2016-05-23T15:21:26Z</dc:date>
    </item>
    <item>
      <title>Re: How Can I Assign a Custom Color set to Gchart lines?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272441#M9717</link>
      <description>&lt;P&gt;I need to reword my question doing some research.&lt;/P&gt;</description>
      <pubDate>Mon, 23 May 2016 15:28:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272441#M9717</guid>
      <dc:creator>DavidPhillips2</dc:creator>
      <dc:date>2016-05-23T15:28:34Z</dc:date>
    </item>
    <item>
      <title>Re: How Can I Assign a Custom Color set to Gchart lines?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272490#M9719</link>
      <description>&lt;P&gt;I wouldn't normally associate GCHART with lines, usually that would be GPLOT. In which case SYMBOL1 through SYMBOL255 are available to assign line characteristics such as color, line type (various dash dot combinations) and thickness.&lt;/P&gt;</description>
      <pubDate>Mon, 23 May 2016 17:45:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272490#M9719</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2016-05-23T17:45:32Z</dc:date>
    </item>
    <item>
      <title>Re: How Can I Assign a Custom Color set to Gchart lines?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272492#M9720</link>
      <description>&lt;P&gt;data test2; set sashelp.workers;&lt;BR /&gt;if electric &amp;gt; 270 then grouping =1;&lt;BR /&gt;else if electric &amp;gt; 255 then grouping =2;&lt;BR /&gt;else grouping =3;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;proc print data=sashelp.workers;&lt;BR /&gt;run;&lt;BR /&gt;proc template;&lt;BR /&gt;define statgraph layoutoverlay;&lt;BR /&gt;begingraph;&lt;BR /&gt;entrytitle "Trends in Employment Levels";&lt;BR /&gt;layout overlay / cycleattrs=true&lt;BR /&gt;xaxisopts=(display=(ticks tickvalues))&lt;BR /&gt;yaxisopts=(label="Number of Workers (thousands)");&lt;BR /&gt;seriesplot x=date y=electric / group=grouping&lt;BR /&gt;curvelabel="Electrical"&lt;BR /&gt;curvelabellocation=outside;&lt;BR /&gt;endlayout;&lt;BR /&gt;endgraph;&lt;BR /&gt;end;&lt;BR /&gt;run;&lt;BR /&gt;proc sgrender data=test2 template=layoutoverlay;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In this example I want to define the first line as purple then yellow then orange.&lt;/P&gt;</description>
      <pubDate>Mon, 23 May 2016 17:51:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272492#M9720</guid>
      <dc:creator>DavidPhillips2</dc:creator>
      <dc:date>2016-05-23T17:51:38Z</dc:date>
    </item>
    <item>
      <title>Re: How Can I Assign a Custom Color set to Gchart lines?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272498#M9721</link>
      <description>&lt;P&gt;I'm trying to merge two template ideas together. &amp;nbsp;One for colors and one for the graph. &amp;nbsp;Not sure on the syntax.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;data test2; set sashelp.workers;&lt;BR /&gt;if electric &amp;gt; 270 then grouping =1;&lt;BR /&gt;else if electric &amp;gt; 255 then grouping =2;&lt;BR /&gt;else grouping =3;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;/*proc print data=sashelp.workers;&lt;BR /&gt;run;*/&lt;BR /&gt;proc template;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;define statgraph layoutoverlay;&lt;BR /&gt;parent=styles.listing;&lt;BR /&gt;style GraphData1 /&lt;BR /&gt;ContrastColor=pink&lt;BR /&gt;Color=pink&lt;BR /&gt;MarkerSymbol="CircleFilled"&lt;BR /&gt;Linestyle=1;&lt;BR /&gt;style GraphData2 /&lt;BR /&gt;ContrastColor=brown&lt;BR /&gt;Color=brown&lt;BR /&gt;MarkerSymbol="TriangleFilled"&lt;BR /&gt;Linestyle=1;&lt;BR /&gt;style GraphData3 /&lt;BR /&gt;ContrastColor=orange&lt;BR /&gt;Color=orange&lt;BR /&gt;MarkerSymbol="SquareFilled"&lt;BR /&gt;Linestyle=1;&lt;BR /&gt;begingraph;&lt;BR /&gt;entrytitle "Trends in Employment Levels";&lt;BR /&gt;layout overlay / cycleattrs=true&lt;BR /&gt;xaxisopts=(display=(ticks tickvalues))&lt;BR /&gt;yaxisopts=(label="Number of Workers (thousands)");&lt;BR /&gt;seriesplot x=date y=electric / group=grouping&lt;BR /&gt;curvelabel="Electrical"&lt;BR /&gt;curvelabellocation=outside;&lt;BR /&gt;endlayout;&lt;BR /&gt;endgraph;&lt;BR /&gt;end;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc sgrender data=test2 template=layoutoverlay;&lt;BR /&gt;run;&lt;/P&gt;</description>
      <pubDate>Mon, 23 May 2016 18:18:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272498#M9721</guid>
      <dc:creator>DavidPhillips2</dc:creator>
      <dc:date>2016-05-23T18:18:08Z</dc:date>
    </item>
    <item>
      <title>Re: How Can I Assign a Custom Color set to Gchart lines?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272520#M9723</link>
      <description>&lt;PRE&gt;data test2;                                                                                                                             

  set sashelp.workers;                                                                                                                  

  if electric &amp;gt; 270 then grouping =1;                                                                                                   

  else if electric &amp;gt; 255 then grouping =2;                                                                                              

  else grouping =3;                                                                                                                     

run;                                                                                                                                    

                                                                                                                                        

proc template;                                                                                                                          

  define statgraph layoutoverlay;                                                                                                       

/* Define the attributes for the data groups */                                                                                         

  begingraph / datacolors=(pink brown orange)                                                                                           

               datacontrastcolors=(pink brown orange)                                                                                   

               datalinepatterns=(1 1 1)                                                                                                 

               datasymbols=(CircleFilled TriangleFilled SquareFilled);                                                                  

                                                                                                                                        

    entrytitle "Trends in Employment Levels";                                                                                           

    entrytitle "Electrical";                                                                                                            

    layout overlay / cycleattrs=true                                                                                                    

           xaxisopts=(display=(ticks tickvalues))                                                                                       

           yaxisopts=(label="Number of Workers (thousands)");                                                                           

      seriesplot x=date y=electric / group=grouping;                                                                                    

    endlayout;                                                                                                                          

  endgraph;                                                                                                                             

  end;                                                                                                                                  

run;                                                                                                                                    

                                                                                                                                        

proc sgrender data=test2 template=layoutoverlay;                                                                                        

run;   &lt;/PRE&gt;</description>
      <pubDate>Mon, 23 May 2016 19:17:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272520#M9723</guid>
      <dc:creator>DavidPhillips2</dc:creator>
      <dc:date>2016-05-23T19:17:06Z</dc:date>
    </item>
    <item>
      <title>Re: How Can I Assign a Custom Color set to Gchart lines?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272523#M9724</link>
      <description>&lt;P&gt;Turns out I actually need to do the same thing with gchart bars. &amp;nbsp;This is done with Patern statements.&lt;/P&gt;</description>
      <pubDate>Mon, 23 May 2016 20:02:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272523#M9724</guid>
      <dc:creator>DavidPhillips2</dc:creator>
      <dc:date>2016-05-23T20:02:24Z</dc:date>
    </item>
    <item>
      <title>Re: How Can I Assign a Custom Color set to Gchart lines?</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272708#M9731</link>
      <description>&lt;P&gt;According to:&lt;/P&gt;&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/grstatproc/67909/HTML/default/viewer.htm#p1dt33l6a6epk6n1chtynsgsjgit.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/grstatproc/67909/HTML/default/viewer.htm#p1dt33l6a6epk6n1chtynsgsjgit.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I need group = panelBy3 for colors to show up here? &amp;nbsp;Can I have the same first color without the group?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;data test2;                                                                                                                             

  set sashelp.workers;                                                                                                                  

  if electric &amp;gt; 270 then grouping =1;                                                                                                   

  else if electric &amp;gt; 255 then grouping =2;                                                                                              

  else grouping =3;                                                                                                                     

  if electric &amp;gt; 270 then panelBy1 =1;                                                                                                   

  else if electric &amp;gt; 255 then panelBy1 =2;                                                                                              

  else panelBy1 =3;   

  if electric &amp;gt; 270 then panelBy2 =1;                                                                                                   

  else if electric &amp;gt; 255 then panelBy2 =2;                                                                                              

  else panelBy2 =3; 

  if electric &amp;gt; 270 then panelBy3 =1;                                                                                                   

  else if electric &amp;gt; 255 then panelBy3 =2;                                                                                              

  else panelBy3 =3; 

run; 

proc sgpanel data=test2 ;
	panelby panelBy1 panelBy2 / layout=lattice uniscale=column novarname columns=4 onepanel headerbackcolor="969491" HEADERATTRS=(Weight=Bold color=white);
	styleattrs datacontrastcolors=(CXFFBA00 black CX969491 CX6341 CX63513D CX768692 CX69B3E7 CX6BCABA CXC6AA76 CXE9DF97 CXC4D600 CXE57200) 
	datacolors=(CXFFBA00 black CX969491 CX6341 CX63513D CX768692 CX69B3E7 CX6BCABA CXC6AA76 CXE9DF97 CXC4D600 CXE57200);
	vbar grouping / response=electric nostatlabel grouporder=ascending group = panelBy3;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;for a single color use:&amp;nbsp;&lt;SPAN&gt;vbar grouping / response=electric nostatlabel fillattrs=(color=CXFFBA00);&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 26 May 2016 12:52:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/How-Can-I-Assign-a-Custom-Color-set-to-Gchart-lines/m-p/272708#M9731</guid>
      <dc:creator>DavidPhillips2</dc:creator>
      <dc:date>2016-05-26T12:52:29Z</dc:date>
    </item>
  </channel>
</rss>

