<?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 find out what the default colors are for my SAS graph in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/794605#M254800</link>
    <description>&lt;P&gt;Use proc template to list the definition of the ODS Style you are using.&lt;/P&gt;
&lt;P&gt;Example:&lt;/P&gt;
&lt;PRE&gt;proc template;
   source styles.htmlblue;
run;&lt;/PRE&gt;
&lt;P&gt;You may need to search for the color definitions depending on exactly which style you place on the Source statement. The colors might be defined in the parent and may need to look at the parent to map other values used for colors.&lt;/P&gt;
&lt;P&gt;The output from the above my system is:&lt;/P&gt;
&lt;PRE&gt;610  proc template;
611     source styles.htmlblue;
define style Styles.Htmlblue;
   parent = styles.statistical;
   class GraphColors /
      'gndata12' = cxECE8C4
      'gndata11' = cxDBD8F8
      'gndata10' = cxC6E4BF
      'gndata9' = cxE6CEAD
      'gndata8' = cxE5C1D4
      'gndata7' = cxCCDFF0
      'gndata6' = cxDDDEB5
      'gndata5' = cxDBC7E7
      'gndata4' = cxD5C6B4
      'gndata3' = cxB7D4D3
      'gndata2' = cxE7B3B4
      'gndata1' = cxBBC2DC
      'gndata' = cxBBC2DC
      'gofill' = cxFAFBFE
      'gblockheader' = cxcfd5de
      'gcphasebox' = cx989EA1
      'gphasebox' = cxDBE6F2
      'gczonec' = cxBECEE0
      'gzonec' = cxCCDCEE
      'gczoneb' = cxCCDCEE
      'gzoneb' = cxD7E5F3
      'gzonea' = cxE3EDF7
      'gconramp3cend' = cx9C1C00
      'gconramp3cneutral' = cx222222
      'gconramp3cstart' = cx0E36AC
      'gramp3cend' = cxD05B5B
      'gramp3cneutral' = cxFAFBFE
      'gramp3cstart' = cx667FA2
      'gcontrollim' = cxE6F2FF
      'gccontrollim' = cxBFC7D9
      'gruntest' = cxCAE3FF
      'gcruntest' = cxBF4D4D
      'gclipping' = cxFFFFC6
      'gcclipping' = cxC1C100
      'gaxis' = cx989EA1
      'greferencelines' = cx989EA1;
   class colors /
      'link2' = cx0000FF
      'link1' = cx800080
      'docbg' = cxFAFBFE
      'contentbg' = cxFAFBFE
      'systitlebg' = cxFAFBFE
      'titlebg' = cxFAFBFE
      'proctitlebg' = cxFAFBFE
      'headerbg' = cxEDF2F9
      'captionbg' = cxFAFBFE
      'captionfg' = cx112277
      'bylinebg' = cxFAFBFE
      'notebg' = cxFAFBFE
      'tablebg' = cxFAFBFE
      'batchbg' = cxFAFBFE
      'systitlefg' = cx112277
      'titlefg' = cx112277
      'proctitlefg' = cx112277
      'bylinefg' = cx112277
      'notefg' = cx112277;
   class Header /
      bordercolor = cxB0B7BB
      backgroundcolor = cxEDF2F9
      color = cx112277;
   class Footer /
      bordercolor = cxB0B7BB
      backgroundcolor = cxEDF2F9
      color = cx112277;
   class RowHeader /
      bordercolor = cxB0B7BB
      backgroundcolor = cxEDF2F9
      color = cx112277;
   class RowFooter /
      bordercolor = cxB0B7BB
      backgroundcolor = cxEDF2F9
      color = cx112277;
   class Table /
      cellpadding = 5;
   class Graph /
      attrpriority = "Color";
   class GraphFit2 /
      linestyle = 1;
   class GraphClipping /
      markersymbol = "circlefilled";
end;
NOTE: Path 'Styles.Htmlblue' is in: SASHELP.TMPLMST.
612  run;
&lt;/PRE&gt;
&lt;P&gt;The Gndataxx replace the default values assigned in the parent style of Styles.Statistical.&lt;/P&gt;
&lt;P&gt;You will need to reference the SAS documentation for colors for the different ways of defining colors. Look in the documentation for "Color Naming Schemes". Here the values are RGB (the CX tells SAS that is the naming type) and the pairs of characters hold hex values of the 256 values possible for each of the reg, green and blue components of the displayed color.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The reference names for the color elements depends on which element. The GraphdataN are the basic names with up to 12 generally.&lt;/P&gt;</description>
    <pubDate>Fri, 04 Feb 2022 20:43:53 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2022-02-04T20:43:53Z</dc:date>
    <item>
      <title>How to find out what the default colors are for my SAS graph</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/794602#M254797</link>
      <description>&lt;P&gt;Dear Community,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am working on a bar graph that uses default colors (color of the bars) and I need to know the code (names) for those colors.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there any way to find out what the code (names) for(of) those exact colors are?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you for any suggestions!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Karoline&lt;/P&gt;</description>
      <pubDate>Fri, 04 Feb 2022 20:27:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/794602#M254797</guid>
      <dc:creator>KarolineN</dc:creator>
      <dc:date>2022-02-04T20:27:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to find out what the default colors are for my SAS graph</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/794605#M254800</link>
      <description>&lt;P&gt;Use proc template to list the definition of the ODS Style you are using.&lt;/P&gt;
&lt;P&gt;Example:&lt;/P&gt;
&lt;PRE&gt;proc template;
   source styles.htmlblue;
run;&lt;/PRE&gt;
&lt;P&gt;You may need to search for the color definitions depending on exactly which style you place on the Source statement. The colors might be defined in the parent and may need to look at the parent to map other values used for colors.&lt;/P&gt;
&lt;P&gt;The output from the above my system is:&lt;/P&gt;
&lt;PRE&gt;610  proc template;
611     source styles.htmlblue;
define style Styles.Htmlblue;
   parent = styles.statistical;
   class GraphColors /
      'gndata12' = cxECE8C4
      'gndata11' = cxDBD8F8
      'gndata10' = cxC6E4BF
      'gndata9' = cxE6CEAD
      'gndata8' = cxE5C1D4
      'gndata7' = cxCCDFF0
      'gndata6' = cxDDDEB5
      'gndata5' = cxDBC7E7
      'gndata4' = cxD5C6B4
      'gndata3' = cxB7D4D3
      'gndata2' = cxE7B3B4
      'gndata1' = cxBBC2DC
      'gndata' = cxBBC2DC
      'gofill' = cxFAFBFE
      'gblockheader' = cxcfd5de
      'gcphasebox' = cx989EA1
      'gphasebox' = cxDBE6F2
      'gczonec' = cxBECEE0
      'gzonec' = cxCCDCEE
      'gczoneb' = cxCCDCEE
      'gzoneb' = cxD7E5F3
      'gzonea' = cxE3EDF7
      'gconramp3cend' = cx9C1C00
      'gconramp3cneutral' = cx222222
      'gconramp3cstart' = cx0E36AC
      'gramp3cend' = cxD05B5B
      'gramp3cneutral' = cxFAFBFE
      'gramp3cstart' = cx667FA2
      'gcontrollim' = cxE6F2FF
      'gccontrollim' = cxBFC7D9
      'gruntest' = cxCAE3FF
      'gcruntest' = cxBF4D4D
      'gclipping' = cxFFFFC6
      'gcclipping' = cxC1C100
      'gaxis' = cx989EA1
      'greferencelines' = cx989EA1;
   class colors /
      'link2' = cx0000FF
      'link1' = cx800080
      'docbg' = cxFAFBFE
      'contentbg' = cxFAFBFE
      'systitlebg' = cxFAFBFE
      'titlebg' = cxFAFBFE
      'proctitlebg' = cxFAFBFE
      'headerbg' = cxEDF2F9
      'captionbg' = cxFAFBFE
      'captionfg' = cx112277
      'bylinebg' = cxFAFBFE
      'notebg' = cxFAFBFE
      'tablebg' = cxFAFBFE
      'batchbg' = cxFAFBFE
      'systitlefg' = cx112277
      'titlefg' = cx112277
      'proctitlefg' = cx112277
      'bylinefg' = cx112277
      'notefg' = cx112277;
   class Header /
      bordercolor = cxB0B7BB
      backgroundcolor = cxEDF2F9
      color = cx112277;
   class Footer /
      bordercolor = cxB0B7BB
      backgroundcolor = cxEDF2F9
      color = cx112277;
   class RowHeader /
      bordercolor = cxB0B7BB
      backgroundcolor = cxEDF2F9
      color = cx112277;
   class RowFooter /
      bordercolor = cxB0B7BB
      backgroundcolor = cxEDF2F9
      color = cx112277;
   class Table /
      cellpadding = 5;
   class Graph /
      attrpriority = "Color";
   class GraphFit2 /
      linestyle = 1;
   class GraphClipping /
      markersymbol = "circlefilled";
end;
NOTE: Path 'Styles.Htmlblue' is in: SASHELP.TMPLMST.
612  run;
&lt;/PRE&gt;
&lt;P&gt;The Gndataxx replace the default values assigned in the parent style of Styles.Statistical.&lt;/P&gt;
&lt;P&gt;You will need to reference the SAS documentation for colors for the different ways of defining colors. Look in the documentation for "Color Naming Schemes". Here the values are RGB (the CX tells SAS that is the naming type) and the pairs of characters hold hex values of the 256 values possible for each of the reg, green and blue components of the displayed color.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The reference names for the color elements depends on which element. The GraphdataN are the basic names with up to 12 generally.&lt;/P&gt;</description>
      <pubDate>Fri, 04 Feb 2022 20:43:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/794605#M254800</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2022-02-04T20:43:53Z</dc:date>
    </item>
    <item>
      <title>Re: How to find out what the default colors are for my SAS graph</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/794658#M254808</link>
      <description>&lt;P&gt;See the article, &lt;A href="https://blogs.sas.com/content/iml/2017/02/06/group-colors-sgplot.html" target="_self"&gt;"What colors does PROC SGPLOT use for markers?"&lt;/A&gt;&amp;nbsp;Although the article talks about marker colors in a scatter plot, you can use similar ideas to find the fill colors in a bar chart.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regarding the color "code" versus "name," the colors probably are only defined in terms of the RGB values (like&amp;nbsp;&lt;SPAN&gt;CX556B2F). However, if you need a color NAME (like "Dark Olive Green"), there is a way to find the closest "color name" to a given RGB color. See &lt;A href="https://blogs.sas.com/content/iml/2022/01/12/closest-color-name.html" target="_self"&gt;"How to assign a name to a color."&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 05 Feb 2022 10:47:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/794658#M254808</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2022-02-05T10:47:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to find out what the default colors are for my SAS graph</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/794666#M254809</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/341969"&gt;@KarolineN&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As &lt;A href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13884" target="_blank" rel="noopener"&gt;ballardw&lt;/A&gt; and &lt;A href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13684" target="_blank" rel="noopener"&gt;Rick_SAS&lt;/A&gt; have explained, you can investigate ODS templates to find out the default color definitions. However, this assumes that you are using ODS graphics (and not traditional SAS/GRAPH output) and that you know the name of the current ODS style. Moreover, you have to match the colored graph elements in front of you to the correct items in a long list of abstract names such as "gndata1" that you read in the ODS template, which I find difficult.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is an alternative, very general approach that I have used in similar situations (using SAS under Windows)&lt;FONT face="helvetica"&gt;:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;STRONG&gt;Step 1:&lt;/STRONG&gt; Take a screenshot of the graph or a relevant part of it to the clipboard. (You can use the convenient Alt+PrtScn keyboard shortcut, a built-in Windows tool such as Snip &amp;amp; Sketch or any other screenshot software.)&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Step 2:&lt;/STRONG&gt; Paste the screenshot into Windows Paint (or other suitable graphics editor software).&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Step 3:&lt;/STRONG&gt; Use the color picker tool (pipette icon) to click on an area of the screenshot with the color in question.&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Step 4:&lt;/STRONG&gt;&amp;nbsp;In Paint: Click the "Edit colors" button (rightmost or second rightmost button of the tool bar). The "Edit colors" dialog then displays the three (decimal)&amp;nbsp;&lt;STRONG&gt;R&lt;/STRONG&gt;ed, &lt;STRONG&gt;G&lt;/STRONG&gt;reen and&amp;nbsp;&lt;STRONG&gt;B&lt;/STRONG&gt;lue values. You can convert these to the hexadecimal system (e.g., using the Windows calculator or the HEX2. format in SAS) if needed for a color specification (cx&lt;EM&gt;RRGGBB&lt;/EM&gt;) in SAS or other purposes.&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Sat, 05 Feb 2022 13:25:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/794666#M254809</guid>
      <dc:creator>FreelanceReinh</dc:creator>
      <dc:date>2022-02-05T13:25:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to find out what the default colors are for my SAS graph</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/795826#M255307</link>
      <description>&lt;P&gt;Thank you very much! This solved my problem &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 12 Feb 2022 10:24:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/795826#M255307</guid>
      <dc:creator>KarolineN</dc:creator>
      <dc:date>2022-02-12T10:24:37Z</dc:date>
    </item>
    <item>
      <title>Re: How to find out what the default colors are for my SAS graph</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/795827#M255308</link>
      <description>&lt;P&gt;Thank you, this is very useful to know!&lt;/P&gt;</description>
      <pubDate>Sat, 12 Feb 2022 10:25:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/795827#M255308</guid>
      <dc:creator>KarolineN</dc:creator>
      <dc:date>2022-02-12T10:25:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to find out what the default colors are for my SAS graph</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/795828#M255309</link>
      <description>&lt;P&gt;Thank you! This is also very useful to know and might come in handy later:)&lt;/P&gt;</description>
      <pubDate>Sat, 12 Feb 2022 10:29:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-find-out-what-the-default-colors-are-for-my-SAS-graph/m-p/795828#M255309</guid>
      <dc:creator>KarolineN</dc:creator>
      <dc:date>2022-02-12T10:29:03Z</dc:date>
    </item>
  </channel>
</rss>

