The metric
tag allows you to add custom metrics to Crosstab reports. This includes popular nets such as Top 2 Box scores, as well as various summary statistics such as median or standard deviation.
1. On a scale from 0 to 10, how likely are you to recommend this product?
optsfrom: series[0..10]
metric: nets {args: 0,1} {desc: Bottom 2 box}
metric: nets {args: 9,10} {desc: Top 2 box}
Details
 The
metric
tag can be added at any stage, but the survey must be published after.  You can add multiple
metric
tags to a question, variable, or list.  When added to a list, all questions utilizing the list will have the defined metric(s) available.
Tag inputs
The following values (inputs) can be used with the metric
tag.
Value  Description 
max 
Displays the maximum value entered in the field. 
min 
Displays the minimum value entered in the field. 
mean

Displays the mathematical average for a field. 
median

Displays the mathematical median for a field. 
nets

Displays counts for given option values. Use the The 
percentile

Displays the count of respondents falling within a specific percentile. Include the 

Displays the count of respondents with response values falling into a given range. Include the args decorator to specify the lower and upper bounds of the range, separated by a comma. 
std_dev 
Displays the standard deviation of values entered in the field. 
transformed_average 
Allows users to recode values selected or entered in the field to other specified values. Include the args decorator to define those values. 
variance 
Displays the variance of values entered in the field. 
Decorators
Decorators are added after the metric
tag to provide additional instructions on how to calculate the data or how to display it in the reports.
Decorator  Description 
args 
Supplies arguments to define the metric. This is required with 
base 
Specifies the options to limit the metric calculations to (e.g., {base: 1..10} ). 
desc

Supplies a name for the metric that appears in reports. 
position 
Displays the position (row) of the metric in the respective Crosstab table (e.g., { 
Additional examples
Adjusting the base of a calculation
The mean calculation uses option IDs as the numeric values as its input. In the example below, if we didn't specify the base, the mean would be calculated from values 1, 2, 3, 4, and 98. The value of 98 would significantly increase the mean, so the base
decorator specifies to only include options 1 through 4 in the calculation.
1. Rate 110, 1 being the Worst and 10 being the Best. N/A if you don't know enough to rate. type: radio table optsfrom: series[1..5] 98. N/A headings: Worst, Best
metric: mean {base: 1..4} {desc: Mean values}
rows:
1. Cat
2. Dog
3. Fish
4. Bird
98. N/A
Applying a metric to a list
You can add any metric to a set list
. In the example below, the 50th percentile will be calculated and displayed in the Crosstab report for all questions using list 1TO7.
setlist: 1TO7 1. 1  Would never do it series: 2..6 7. 7  Absolutely would do it metric: percentile {args: 50} {desc: 50th percentile}
2. If cost were not an issue, would you fly to the moon?
type: radio
optsfrom: 1TO7
Question using a range
You can use the range
metric to count the number of respondents whose answers fall within a specified range. You must also add the args
decorator to specify the lowest and highest values, separated by a comma.
3. How many times have you skydived? type: integer range: 0  99999 size: 5
postfix: times metric: range {args: 0, 1000} {desc: 1000 and under} metric: range {args: 1001, 99999} {desc: 1000 and over}
NPS nets and transformed average
NPS questions use multiple metrics to create nets (groupings) for detractors, passives, and promoters. Then, the transformed_average
metric is used to calculate the score.
In Q5A below, you see all metrics applied to a standard NPS question. In Q5B, we use our system class to achieve the same result.
5A. On a scale of 0  10, how likely would you be to recommend our hotel? type: radio hscale: y headings: Not at all likely, Extremely likely optsfrom: series[0..10] metric: nets {args: 0..6} {desc: Detractors} metric: nets {args: 7,8} {desc: Passives} metric: nets {args: 9,10} {desc: Promoters} metric: transformed_average {args: 0..6 == 100; 7,8 == 0; 9,10 == 100} {desc: NPS}
5B. On a scale of 0  10, how likely would you be to recommend our hotel?
class: nps
NPS groups are displayed automatically in Topline reports in r8 software versions.
Comments
0 comments
Please sign in to leave a comment.