ArcGIS Dashboard Removing Digits on Indicator Widget

170
0
07-08-2021 09:37 PM
Labels (1)
ArizonaGIS
New Contributor

I am attempting to reference an outage dashboard that shows 99.999% availability of a network for a calendar year. I am using an auto-calculation logic through S123 to indicate the start date/time of the outage and the resolution date/time of the outage. The total number value is being run against 525600, representing the number of minutes in a year. I have an arcade script showing the decimal record, but it shows 99.92395437262357 vs. just the five digits. I have included my script.

 

var reference = $datapoint["sum_total_time_V03"];
var difference = 525600-reference;
var absoluteDifference = abs(difference);
var ratio = 525600/reference;
var ratioChange = difference/reference;
var percentage = ratio*00.001;
var percentChange = ratioChange*1

return {
    //textColor:'',
    //backgroundColor:'',
    topText: percentage,
    topTextColor: '',
    topTextOutlineColor: '',
    topTextMaxSize: 'medium',
    //iconName:'',
    //iconAlign:'left',
    //iconColor:'',
    //iconOutlineColor:'',
    //noValue:false,
    //attributes: {
      // attribute1: '',
      // attribute2: ''
    // }
  }

 

Tags (2)
0 Kudos
0 Replies