Skip to content

Latest commit

 

History

History
76 lines (66 loc) · 2.14 KB

README.md

File metadata and controls

76 lines (66 loc) · 2.14 KB

Custom Chart Viz

Custom Chart Viz is built upon Apache ECharts library. It allows you to build a chart by custom option

Installation

splunkbase: https://splunkbase.splunk.com/app/5261/

Development Install and Build

export SPLUNK_HOME
cd $SPLUNK_HOME/etc/apps/custom_chart_viz/appserver/static/visualizations/custom_chart_viz
npm install
npm run build
splunk restart

Usage

Sample data can be found in the custom_chart_viz/lookups folder, add those data into Splunk and try following visualizations.

Custom

* SPL
    ```
    | inputlookup spc.csv
    | table no,UCL,LCL,Center,Data,"Out of Limits","Run of 7"
    ```
* Data Type -> Custom
* Option -> copy echarts options,e.g.:
    ```
     {  
        xAxis: {
            type: 'category',
            boundaryGap: false
        }, 
        yAxis: {
            type: 'value',
            scale: true,
            axisLine: { show: false }
        },
        series: [{ 
                type: 'line'
            },
            { 
                type: 'bar'
            },
            { 
                type: 'scatter'
            },
            { 
                type: 'bar' 
            },
            { 
                type: 'scatter' 
            },
            {
                type: 'scatter' 
            }
        ]
    }   
    ```
* xAxis Data Index Binding -> Data index corresponding to the x-axis ,e.g.: 1
* Series Data Index Binding -> Data index corresponding to the series , e.g.:1,2,3,4,5

XBar R - X

  • SPL
    | inputlookup spc.csv
    | table no,UCL,LCL,Center,Data,"Out of Limits","Run of 7"