Walkthrough: Discrete List
One of the more powerful analytic features of Data Discovery relates to using parameters inside formulas. Inclusion of parameters allows users to change the definitional construct of a formula at run time, simply by using parameter slicers. In Pyramid, users can easily build formulas based on global or numeric parameters, and then use those formulas as a dynamic parameter slicer to perform what-if data analysis. For instance, a user may wish to project sales and net profit figures if their top 10 products were sold for double their current price.
STEP 1
From Type, choose Number.
STEP 2
In Members, select the numeric values you want to apply to your global parameter. In Caption, add a name for each row. To follow this example, add the captions and values displayed in the image below:
STEP 3
In Default Value, select the value that will be applied by default when adding the parameter to a query. In this example, the actual value will be displayed by default:
STEP 4
In Visualization, select a slicer type, and then save your parameter.
STEP 5
Open the Formula tool and select the server, database, and data model where you want the parameterized custom member to be located.
STEP 6
Add one of the elements nodes (Data Point, Member, or Set) to the canvas. In this example, the data point node was added, and the clothing element and sales measure were selected.
STEP 7
Add the Numeric Parameter node to the canvas, and find and select your parameter from the content tree.
STEP 8
Add a calculation to your formula, and save.
STEP 9
To open your formula in Discover right away, click Quick Discovery from the ribbon. Your formula will automatically be added to the drop zones.
STEP 10
To access the formula in Discover later on, open Discover and click the show business logic icon in the Measures panel. Find and select your formula in the content tree.
The following example explains how to build a 'Top N' parameter, that will be used to inject the top n results into the query at runtime. First, a discrete list numeric parameter is built, and then injected into a custom list. The parameterized list is then used as a slicer in the query.
STEP 1
If building a numeric model parameter, start by selecting Number.
In Members, select the numeric values you want to apply to your global parameter. In Caption, add a name for each row.
STEP 2
In Default Value, select the value that will be applied by default when adding the parameter to a query.
STEP 3
In Visualization, select a slicer type, and then save your parameter.
STEP 4
Open the List tool and the select server, database, and data model you want to add the custom set or member to (if building a . In this example, a custom set was built in Lists. First the Standard Set node was added, and all the elements within the Product hierarchy were selected.
STEP 5
Add a filter node. In this example, the Top Count node is added.
STEP 6
Under Arguments, select the Parameter option.
STEP 7
The content tree will appear - select your parameter.
STEP 8
Save your list and open Discover. To open your parameter in Discover right away, click Quick Discover in the ribbon. The parameter will automatically be added to the drop zones.
STEP 9
To add the parameter to a query later on, open Discover and select the data model where the list was saved. Find the hierarchy containing your global parameter in the Dimensions panel, right click on it, and select View Elements.
STEP 10
Click the show business logic icon , and find your parameter in the content tree.
STEP 11
Add your parameter to rows, columns, or filters.