Version 2021

Creating functions using the Insert Function Wizard

You can use these functions in metrics, attribute form expressions, fact expressions, custom expression qualifications, and transformation expressions.

To create a function using the Insert Function Wizard

  1. Open the Insert Function Wizard. (How?)

  2. On the Select Function page, navigate through the folders to locate the function to use. Select the function and do one of the following:

    • Click Finish to exit the wizard and enter the argument values of the functions manually.

    • Click Next to access the next page of the wizard for more help in constructing the function. Continue with the steps below.

    Not all functions require arguments and parameters, so you may not see all of the pages described in the following steps.

  3. On the Arguments page, each argument has an input box and a browse button. For each argument listed, enter a value or click Browse to find the metric, fact, prompt, or attribute to use.

    For more information on this page, see Insert Function Wizard: Arguments.

  4. When you have entered all the arguments, click Next to continue.

    If Next is not enabled, the function does not require any further input. Click Finish to enter the function into the expression.

  5. On the Parameters page, all the function's parameters are listed. Set the parameters in one of the following ways:

    • Select the option from the drop-down list, which is available only if the parameter has fixed options.

    • Enter the value of the parameter.

    For more information on this page, see Insert Function Wizard: Parameters.

  6. Select whether to Show function parameters in the formula when viewed in the expression box. This controls whether the parameters are shown in the expression once you return to the Metric Editor.

    This option is available only when the wizard is accessed from the Metric Editor.

  7. When you have set all the parameters, click Next to continue.

    If Next is not enabled, the function does not require any further input. Click Finish to enter the function into the expression.

  8. On the Break-By page, click Add. The Select Objects dialog box opens.

    For more information on this page, see Insert Function Wizard: Break-By.

  9. From the Available objects list, select the attributes and/or hierarchies which will reset the calculation. Click > to add them to the Selected objects list. Click OK to return to the Break-By page.

  10. If you need to remove a break by parameter, select it and click Remove.

  11. If you need to remove all the break by parameters, click Reset.

  12. When you have added all the break by parameters, click Next to continue.

    If Next is not enabled, the function does not require any further input. Click Finish to enter the function into the expression.

  13. On the Sort-By page, select the method of sorting:

    • Sort by objects.

    • Sort by value of the subexpression, which is the input argument. For example, if you define a metric as RunningSum(Metric1), then Metric1 is the subexpression.

    For more information on this page, see Insert Function Wizard: Sort-By.

  14. If you selected Sort by objects:

    • Click Add. The Select Objects dialog box opens.

    • From the Available objects list, select the objects to sort by and click > to add them to the Selected objects list.

    • Click OK to return to the Sort-By page.

    • To remove a sort object, select it and click Remove.

    • To move a sort object in the sort order, select it and click the Up or Downarrow.

    • To select a different form of the object, use the drop-down list in the Special column. Once you change it from the default setting, you can change Order to Ascending or Descending.

  15. If you chose Sort by value of the subexpression, select whether to sort ascending or descending.

  16. Click Finish. You are returned to the original editor, with the new function and its selected arguments and parameters in the expression.

For information on using the new function in a metric, see Using advanced functions in metrics.