agg_dist_plotter module

class AggDistPlotter(time_units, conn)

Bases: ABC

The AggDistPlotter module lets you view macro values for your variables and find the distribution between them and the largest contributors.

This module requires your data to follow the default eimerdb structure and requires som specific variables defined in the variable selector.

Note

Current implementation is very locked into a specific data structure.

Parameters:
  • time_units (list[str])

  • conn (object)

abstract layout()

Define the layout for the Aarsregnskap module.

This is an abstract method that must be implemented by subclasses to define the module’s layout.

Returns:

A Dash HTML Div component representing the layout of the module.

Return type:

html.Div

module_callbacks()

Defines the callbacks for the AggDistPlotter module.

Return type:

None

update_partition_select(partition_dict, key_to_update)

Updates the partition select dictionary.

Adds the previous value (N-1) to the list for a single specified key.

Parameters:
  • partition_dict (dict[str, list[int | str]]) – Dictionary containing lists of values

  • key_to_update (str) – Key to update by appending (N-1)

Return type:

dict[str, list[int | str]]

Returns:

Updated dictionary

class AggDistPlotterTab(time_units, conn)

Bases: TabImplementation, AggDistPlotter

AggDistPlotterTab is an implementation of the AggDistPlotter module as a tab in a Dash application.

Parameters:
  • time_units (list[str])

  • conn (object)

class AggDistPlotterWindow(time_units, conn)

Bases: WindowImplementation, AggDistPlotter

AggDistPlotterWindow is an implementation of the AggDistPlotter module as a tab in a Dash application.

Parameters:
  • time_units (list[str])

  • conn (object)