Item Groups. Improving the efficiency of calculations

2

Hello everyone!
For those who appreciate the effectiveness of calculations in QM, I will show here how to select information from grouped items of categories. Purpose: to demonstrate the benefits and capabilities of QM. The result of the demonstration will be to reduce the number of formulas to a single one. A small number of formulas to achieve the result is one of the significant advantages of QM. How to achieve this advantage, I will show below on two cases known to experienced QM users. Sampling from item groups and recursion by item groups are not always obvious and easy to use. Therefore, it is on the item groups that I focus my attention. So let’s take a look.

Answered question
2

Case 1. The “Time Demo. model” model I saw in this post.
“Author has taken the approach to put all time elements (months, quarters and year total) within a single time category. He then creates four formulas to obtain the quarterly values…
I reproduced part of this model and the author’s logic on dummy data in Variant 1 (Formulas 4 through 7).
*

*

*
In Variant 2, QM did the same calculations for quarterly values with just one formula (Formulas 8). Formulas 8 logic can also be implemented based on the SelectBetween() function:
*

*

Answered question
2

Case 2. Model: “World Cup Model – quantrix_-_world_cup_model.model” – even more interesting in terms of the stated theme of the post. This model can not longer be downloaded, but there is still a link to its formulas on the Internet.
I reproduced part of this model with the author’s data. This model uses the matrix with the category Team Group whose 32 elements are divided into groups of 4. In each of the 8 groups it is necessary to calculate intra-group ranks. The author of the model for this uses 8 formulas (see Rank.AsIs: Formulas 1 Through 8). However, QM allows you to calculate all intra-group ranks with just one formula (see Rank.AsItSB: Formula 9).
***
*

***
**
*
As you can see, QM provides the ability to write compact and easy-to-understand formulas when using data structures with groups of items.
*
By the way, the logic of these formulas (see Rank.AsIs: Formulas 1 through 8) is imprecise and allows 5 ranks (0 through 4) for 4 numbers. For example, if Uruguay and England have the same Tie Breaker values, then Rank.AsItSB (Formula 9) calculates the ranks correctly:
*

*
I invite QM users to speak up and evaluate the capabilities of QM.
***
Good luck

Answered question