atoti.Level#

class atoti.Level#

Level of a Hierarchy.

A level is a sub category of a hierarchy. Levels have a specific order with a parent-child relationship.

In a Pivot Table, a single-level hierarchy will be displayed as a flat attribute while a multi-level hierarchy will display the first level and allow users to expand each member against the next level and display sub totals.

For example, a Geography hierarchy can have a Continent as the top level where Continent expands to Country which in turn expands to the leaf level: City.

data_type

Type of the level members.

dimension

Name of the dimension holding the level.

hierarchy

Name of the hierarchy holding the level.

isin

Return a condition to check that the level is on one of the given members.

isnull

Return a condition evaluating to True when a level is not expressed in a query and False otherwise.

name

Name of the level.

order

Order in which to sort the level's members.