<?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: Change color of column in chart using 2 fields in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/Change-color-of-column-in-chart-using-2-fields/m-p/525936#M35675</link>
    <description>&lt;P&gt;You can setup your chart item and edit and switch to sources:&lt;/P&gt;&lt;P&gt;You would then put something in like such:&lt;BR /&gt;&lt;BR /&gt;&amp;lt;option name="charting.fieldColors"&amp;gt;{"0-30": 0x009900, "31-60": 0xFF6600, "61-90": 0x66CCFF, "91-180": 0xFFFF00, "Older than 180": 0xFF0000}&amp;lt;/option&amp;gt;&lt;BR /&gt;&lt;BR /&gt;if you just use an array: (not perferred):&lt;BR /&gt;&lt;BR /&gt;This one is not good (if there are not any matches for certain states of days; you risk colors to be matched to the first entry in the array. not the color you desire;&amp;nbsp; unless you do some make results stuff to for each state in your output of your search to ensure all states show up 0-30,31-60,61-90,91-180, older than 180.&lt;/P&gt;&lt;P&gt;&amp;lt;option name="charting.seriesColors"&amp;gt;[0x009900, 0xFF6600, 0x66CCFF, 0xFFFF00,0xFF000]&amp;lt;/option&amp;gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;to sample below;&amp;nbsp; you can use HEX Color editor to pick your preferred Shades of Colors.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;lt;panel&amp;gt;&lt;BR /&gt;&amp;lt;title&amp;gt;CRITICAL&amp;lt;/title&amp;gt;&lt;BR /&gt;&amp;lt;chart&amp;gt;&lt;BR /&gt;&amp;lt;search&amp;gt;&lt;BR /&gt;&amp;lt;query&amp;gt;&lt;BR /&gt;index=qualys_host_detection TYPE=CONFIRMED ("severity=3" OR "severity=4" OR "severity=5") OS="Windows Server*" OR "Microsoft Windows Server" OR "VMWare" STATUS!=FIXED | dedup QID, HOST_ID | eval firstseen=strptime(FIRST_FOUND_DATETIME, "%Y-%m-%dT%H:%M:%S"), epochnow=now(), duration=round((epochnow-firstseen)/86400,0), days=case(duration&amp;lt;=30, "0-30", duration&amp;gt;30 AND duration&amp;lt;=60, "31-60", duration&amp;gt;60 AND duration&amp;lt;=90, "61-90", duration&amp;gt;90 AND duration&amp;lt;=180, "91-180", duration&amp;gt;180, "Older than 180") | stats count by days&lt;BR /&gt;&amp;lt;/query&amp;gt;&lt;BR /&gt;&amp;lt;/search&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.axisTitleX.visibility"&amp;gt;visible&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.axisTitleY.visibility"&amp;gt;visible&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.axisTitleY2.visibility"&amp;gt;visible&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.chart"&amp;gt;pie&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.drilldown"&amp;gt;none&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.legend.placement"&amp;gt;right&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.fieldColors"&amp;gt;{"0-30": 0x009900, "31-60": 0xFF6600, "61-90": 0x66CCFF, "91-180": 0xFFFF00, "Older than 180": 0xFF0000}&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;/chart&amp;gt;&lt;BR /&gt;&amp;lt;/panel&amp;gt;&lt;/P&gt;</description>
    <pubDate>Wed, 21 Oct 2020 23:51:53 GMT</pubDate>
    <dc:creator>kennetkline</dc:creator>
    <dc:date>2020-10-21T23:51:53Z</dc:date>
    <item>
      <title>Change color of column in chart using 2 fields</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Change-color-of-column-in-chart-using-2-fields/m-p/525883#M35669</link>
      <description>&lt;P&gt;I have a search query that gives me a count of vulnerabilities broken down by age (in days).&amp;nbsp; I want to be able to have a different color for each column.&amp;nbsp; The columns are, in days, 0-30 (light green), 31-60 (orange), 61-90 (light blue), 91-180 (yellow), and Older than 180 (red).&amp;nbsp; When I use 'charting.seriesColors', all of the columns turn light green.&lt;/P&gt;&lt;P&gt;Search query:&lt;/P&gt;&lt;P&gt;&amp;nbsp;index=qualys_host_detection TYPE=CONFIRMED ("severity=3" OR "severity=4" OR "severity=5") OS="Windows Server*" OR "Microsoft Windows Server" OR "VMWare" STATUS!=FIXED | dedup QID, HOST_ID | eval firstseen=strptime(FIRST_FOUND_DATETIME, "%Y-%m-%dT%H:%M:%S"), epochnow=now(), duration=round((epochnow-firstseen)/86400,0), days=case(duration&amp;lt;=30, "0-30", duration&amp;gt;30 AND duration&amp;lt;=60, "31-60", duration&amp;gt;60 AND duration&amp;lt;=90, "61-90", duration&amp;gt;90 AND duration&amp;lt;=180, "91-180", duration&amp;gt;180, "Older than 180") | stats count by days&lt;/P&gt;</description>
      <pubDate>Wed, 21 Oct 2020 18:41:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Change-color-of-column-in-chart-using-2-fields/m-p/525883#M35669</guid>
      <dc:creator>ddergan</dc:creator>
      <dc:date>2020-10-21T18:41:44Z</dc:date>
    </item>
    <item>
      <title>Re: Change color of column in chart using 2 fields</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Change-color-of-column-in-chart-using-2-fields/m-p/525936#M35675</link>
      <description>&lt;P&gt;You can setup your chart item and edit and switch to sources:&lt;/P&gt;&lt;P&gt;You would then put something in like such:&lt;BR /&gt;&lt;BR /&gt;&amp;lt;option name="charting.fieldColors"&amp;gt;{"0-30": 0x009900, "31-60": 0xFF6600, "61-90": 0x66CCFF, "91-180": 0xFFFF00, "Older than 180": 0xFF0000}&amp;lt;/option&amp;gt;&lt;BR /&gt;&lt;BR /&gt;if you just use an array: (not perferred):&lt;BR /&gt;&lt;BR /&gt;This one is not good (if there are not any matches for certain states of days; you risk colors to be matched to the first entry in the array. not the color you desire;&amp;nbsp; unless you do some make results stuff to for each state in your output of your search to ensure all states show up 0-30,31-60,61-90,91-180, older than 180.&lt;/P&gt;&lt;P&gt;&amp;lt;option name="charting.seriesColors"&amp;gt;[0x009900, 0xFF6600, 0x66CCFF, 0xFFFF00,0xFF000]&amp;lt;/option&amp;gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;to sample below;&amp;nbsp; you can use HEX Color editor to pick your preferred Shades of Colors.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;lt;panel&amp;gt;&lt;BR /&gt;&amp;lt;title&amp;gt;CRITICAL&amp;lt;/title&amp;gt;&lt;BR /&gt;&amp;lt;chart&amp;gt;&lt;BR /&gt;&amp;lt;search&amp;gt;&lt;BR /&gt;&amp;lt;query&amp;gt;&lt;BR /&gt;index=qualys_host_detection TYPE=CONFIRMED ("severity=3" OR "severity=4" OR "severity=5") OS="Windows Server*" OR "Microsoft Windows Server" OR "VMWare" STATUS!=FIXED | dedup QID, HOST_ID | eval firstseen=strptime(FIRST_FOUND_DATETIME, "%Y-%m-%dT%H:%M:%S"), epochnow=now(), duration=round((epochnow-firstseen)/86400,0), days=case(duration&amp;lt;=30, "0-30", duration&amp;gt;30 AND duration&amp;lt;=60, "31-60", duration&amp;gt;60 AND duration&amp;lt;=90, "61-90", duration&amp;gt;90 AND duration&amp;lt;=180, "91-180", duration&amp;gt;180, "Older than 180") | stats count by days&lt;BR /&gt;&amp;lt;/query&amp;gt;&lt;BR /&gt;&amp;lt;/search&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.axisTitleX.visibility"&amp;gt;visible&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.axisTitleY.visibility"&amp;gt;visible&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.axisTitleY2.visibility"&amp;gt;visible&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.chart"&amp;gt;pie&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.drilldown"&amp;gt;none&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.legend.placement"&amp;gt;right&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;option name="charting.fieldColors"&amp;gt;{"0-30": 0x009900, "31-60": 0xFF6600, "61-90": 0x66CCFF, "91-180": 0xFFFF00, "Older than 180": 0xFF0000}&amp;lt;/option&amp;gt;&lt;BR /&gt;&amp;lt;/chart&amp;gt;&lt;BR /&gt;&amp;lt;/panel&amp;gt;&lt;/P&gt;</description>
      <pubDate>Wed, 21 Oct 2020 23:51:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Change-color-of-column-in-chart-using-2-fields/m-p/525936#M35675</guid>
      <dc:creator>kennetkline</dc:creator>
      <dc:date>2020-10-21T23:51:53Z</dc:date>
    </item>
    <item>
      <title>Re: Change color of column in chart using 2 fields</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Change-color-of-column-in-chart-using-2-fields/m-p/526054#M35690</link>
      <description>&lt;P&gt;Thanks, kennetkline.&amp;nbsp; I have tried what you have suggested, but it changes all of the columns to the color listed first.&amp;nbsp; I need to figure out how to change all of the columns to their respective colors.&lt;/P&gt;</description>
      <pubDate>Thu, 22 Oct 2020 15:23:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Change-color-of-column-in-chart-using-2-fields/m-p/526054#M35690</guid>
      <dc:creator>ddergan</dc:creator>
      <dc:date>2020-10-22T15:23:57Z</dc:date>
    </item>
    <item>
      <title>Re: Change color of column in chart using 2 fields</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Change-color-of-column-in-chart-using-2-fields/m-p/526078#M35695</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Ok, columns (Table) I was thinking Chart.&amp;nbsp; was late last night&lt;/P&gt;&lt;P&gt;You want to use the paint brush on the Column -&amp;gt; Color -&amp;gt; Values -&amp;gt; Defined Values&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 659px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/11447i8A7A4537DA1C9489/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;format type="color" field="days"&amp;gt;
&amp;lt;colorPalette type="map"&amp;gt;{"0-30":#B6C75A,"31-60":#F1813F,"61-90":#62B3B2,"91-180":#F8BE34,"Older than 180":#DC4E41}&amp;lt;/colorPalette&amp;gt;
&amp;lt;/format&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 22 Oct 2020 18:18:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Change-color-of-column-in-chart-using-2-fields/m-p/526078#M35695</guid>
      <dc:creator>kennetkline</dc:creator>
      <dc:date>2020-10-22T18:18:40Z</dc:date>
    </item>
    <item>
      <title>Re: Change color of column in chart using 2 fields</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Change-color-of-column-in-chart-using-2-fields/m-p/526481#M35729</link>
      <description>&lt;P&gt;I can get the colors to change when using the paint brush, but I am still having an issue when it comes to the column chart.&amp;nbsp; All of the columns change to the first color listed.&amp;nbsp; The above code for the color pallete did not change anything.&lt;/P&gt;</description>
      <pubDate>Mon, 26 Oct 2020 15:54:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Change-color-of-column-in-chart-using-2-fields/m-p/526481#M35729</guid>
      <dc:creator>ddergan</dc:creator>
      <dc:date>2020-10-26T15:54:24Z</dc:date>
    </item>
  </channel>
</rss>

