Filter all metrics or KPIs in this Argument by name and return a new Argument that only contains the entries that match the input names. Matching is case insensitive and can include wild cards. 

var subsetOfMetrics = metrics.filter('*issues'); 

The above example will search the metrics in the argument for all those that match the wildcard expression *Issues. If none match this expression an empty Argument object will be returned. 

Filter functions can also accept javascript regular expressions as filters. The previous example could be rewritten as, note the need to account for case when using javascript RegEx filter.

var subsetOfMetrics = metrics.filter(/.+[Ii]ssues/); 

Did this answer your question?