Dashboards & Visualizations

Display TV guide style UI in dashboard

prashantku
New Member

I am new to Splunk and I need to display my data in typical TV guide format.

X axis is list of channels
Y axis is timeline with scroll bar to go left and right of the current time.
Each row of the line is a variable length rectangles that show the program.

What is the best way to achieve this in splunk dashboard?

0 Karma
1 Solution

anmolpatel
Builder

1) Install the Event Timeline Viz
https://splunkbase.splunk.com/app/4370/

2) Here is a sample query. After execution, go to Visualisation, and select Event Timeline Viz. You will see the result displayed like a TV guide.

| makeresults 
| eval raw = "Channel1%Show1%6:00:00 PM%7:00:00 PM;Channel1%Show2%7:00:00 PM%8:00:00 PM;Channel1%Show3%8:00:00 PM%9:00:00 PM;Channel2%ShowA%5:00:00 PM%6:00:00 PM;Channel2%ShowB%6:00:00 PM%6:30:00 PM;Channel2%ShowC%6:30:00 PM%8:00:00 PM;Channel3%ShowA%7:00:00 PM%8:00:00 PM;Channel3%ShowB%8:00:00 PM%8:30:00 PM;Channel3%ShowC%8:30:00 PM%9:00:00 PM" 
| makemv raw delim=";" 
| mvexpand raw 
| rex field=raw "(?P<Channel>[^\%]+)%(?P<Show>[^\%]+)%(?P<Start_Time>[^\%]+)%(?P<Finish_Time>[^\%]+)"
| eval time_1 = strptime(Start_Time, "%H:%M:%S %p")
| eval time_2 = strptime(Finish_Time, "%H:%M:%S %p")
| eval duration = time_2 - time_1
| eval group = Channel, label = Show, start = time_1, end = time_2, tooltip = Show
| table group, label, start, end, tooltip

alt text

View solution in original post

0 Karma

anmolpatel
Builder

1) Install the Event Timeline Viz
https://splunkbase.splunk.com/app/4370/

2) Here is a sample query. After execution, go to Visualisation, and select Event Timeline Viz. You will see the result displayed like a TV guide.

| makeresults 
| eval raw = "Channel1%Show1%6:00:00 PM%7:00:00 PM;Channel1%Show2%7:00:00 PM%8:00:00 PM;Channel1%Show3%8:00:00 PM%9:00:00 PM;Channel2%ShowA%5:00:00 PM%6:00:00 PM;Channel2%ShowB%6:00:00 PM%6:30:00 PM;Channel2%ShowC%6:30:00 PM%8:00:00 PM;Channel3%ShowA%7:00:00 PM%8:00:00 PM;Channel3%ShowB%8:00:00 PM%8:30:00 PM;Channel3%ShowC%8:30:00 PM%9:00:00 PM" 
| makemv raw delim=";" 
| mvexpand raw 
| rex field=raw "(?P<Channel>[^\%]+)%(?P<Show>[^\%]+)%(?P<Start_Time>[^\%]+)%(?P<Finish_Time>[^\%]+)"
| eval time_1 = strptime(Start_Time, "%H:%M:%S %p")
| eval time_2 = strptime(Finish_Time, "%H:%M:%S %p")
| eval duration = time_2 - time_1
| eval group = Channel, label = Show, start = time_1, end = time_2, tooltip = Show
| table group, label, start, end, tooltip

alt text

0 Karma

niketn
Legend

@prashantku you can try out Timeline Custom Visualization built by Splunk.

____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
0 Karma

richgalloway
SplunkTrust
SplunkTrust

timechart will give you a timeline on the x axis and data on the y axis. The transpose command will swap those. Perhaps that will get you going in the right direction. If not, please elaborate on what you want and include some sample data.

---
If this reply helps you, Karma would be appreciated.
0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Leveraging Automated Threat Analysis Across the Splunk Ecosystem

Are you leveraging automation to its fullest potential in your threat detection strategy?Our upcoming Security ...

Can’t Make It to Boston? Stream .conf25 and Learn with Haya Husain

Boston may be buzzing this September with Splunk University and .conf25, but you don’t have to pack a bag to ...

Splunk Lantern’s Guide to The Most Popular .conf25 Sessions

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...