Splunk Search

Change Chart Increment (X Axis)

henryt1
Path Finder

I have a dashboard created with a few different things in it, and when I left the office on Friday my 'Sessions' count was only showing whole numbers in that particular chart. However, when I came in this morning, it's showing in 0.25 increments (in the X axis). How could I change this back to whole numbers?

Thanks,

Tyler

1 Solution

cphair
Builder

I suspect you'll need to use this charting parameter, assuming you're in simple XML:


<option name="charting.axisLabelsX.integerUnits">true</option>

UPDATE: Given that you're using a bar graph, try setting charting.axisLabelsY.integerUnits to true instead. I just tested it on a view of my own, and the axisLabelsY parameter affected the dependent axis, which for a bar graph is the horizontal one. Go figure.

You can read about the other available parameters for axes and gridlines at http://docs.splunk.com/Documentation/Splunk/4.3.3/Developer/CustomChartingConfig-AxisGrid

View solution in original post

henryt1
Path Finder

Where in the XML would this go? I've tried several places and nothing is working. Right now it looks like this:



*
Live Sessions (Past Hour)
-1h@h
now


bar
gaps
false
default
false
none

""
""
""


0 Karma

henryt1
Path Finder

The change to the Y axis like you mentioned above got it, thanks! Oh and for the search string I listed I just took out the search I'm doing when I posted it on here.

0 Karma

cphair
Builder

@henryt1, I updated my answer above. Did you modify your XML from what appears in your dashboard? searchString is miscapitalized, and I'm not sure what you're doing a bar graph over since your search has no statistical command.

0 Karma

cphair
Builder

I suspect you'll need to use this charting parameter, assuming you're in simple XML:


<option name="charting.axisLabelsX.integerUnits">true</option>

UPDATE: Given that you're using a bar graph, try setting charting.axisLabelsY.integerUnits to true instead. I just tested it on a view of my own, and the axisLabelsY parameter affected the dependent axis, which for a bar graph is the horizontal one. Go figure.

You can read about the other available parameters for axes and gridlines at http://docs.splunk.com/Documentation/Splunk/4.3.3/Developer/CustomChartingConfig-AxisGrid

Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...