Jump to content

Scorecard with variable time periods


Recommended Posts

Hi Seeq Team, 

I'm trying to create a SEEQ scorecard with variable times for the average. Here is the code I'm using to create the condition:

$time = now()

$lastTwo = capsule($time-2min, $time).setProperty('TimeRange', "Last Two Minutes")
$lastHour = capsule($time-1h, $time).setProperty('TimeRange','Last Hour')
$lastDay = capsule($time-1d, $time).setProperty('TimeRange', 'Last Day')

condition(2d, $lastDay, $lastHour, $lastTwo)

And then once I added the scorecard metric, I added TimeRange to the header in capsule property-property name but instead of getting Last two minutes, last hour and last day I just get last day. How do I get the last 2 minutes and last hour to show as well?

Thanks, 

Jack

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...