Forum Discussion
manthena2020
2 years agoAdvisor
Groovy Script For Complex DataPoint
import com.santaba.agent.groovyapi.api.DataCollectionAPI
def dataPointName = "Running"
def day = System.currentTimeMillis() - 1 * 24 * 60 * 60 * 1000
def historicalData = DataCollectionAPI.getHistoricalData(dataPointName,day, System.currentTimeMillis())
def maxRunningWithinWeek = historicalData.max()
return maxRunningWithinWeek
Related Content
- 4 months ago
- 4 months ago
- 2 years ago