Return the number of Facts in the metric or KPI FactList that do not have a value. This can be used to check for missing data that is expected. 

var ping = metrics.get('ping response');
var total = ping.size();
var failed = ping.countNaN();
var slow = ping.countGreaterThan(500);

var availability = (total - (failed+slow)) * 100 / total;
return {
    value : availability,
    sample : total
Did this answer your question?