Skip to content

Managing Calculations

Notes:

Web is currently in feature preview and as such documentation for this feature is still work in progress

This page explains how to create, view, edit, and delete centralized calculations in xpna. These operations are essential for maintaining a library of reusable calculations across dashboards.

Viewing Calculations

All users can view the list of available calculations in their workspace:

  • The calculations list is displayed on the left side of the Calculations page.
  • Each calculation shows its name and the number of dashboards using it (in parentheses).
  • Click on any calculation in the list to view its details in the right panel.

Filtering Calculations

To quickly find a specific calculation:

  • Use the filter input at the top of the calculations list.
  • Type any part of the calculation name to filter the list.
  • The list updates in real-time as text is entered.

Refreshing the List

To ensure the calculations list is up to date:

  • Click the refresh button at the top right of the calculations list.
  • This retrieves the latest calculations from the server.

Creating a New Calculation

Note:

Only workspace administrators can create new calculations.

To create a new calculation:

  • Click the plus (+) button at the top right of the calculations list.
  • A new calculation is created with the default name "New Calculation".
  • The calculation opens in edit mode in the right panel.
  • Enter a descriptive name for the calculation.
  • Build the calculation formula using the formula editor (see Building Calculation Formulas).
  • Optionally, specify a number format (see Number Formatting).
  • Click the save button to save the calculation.

Note:

Calculation names must be unique within the workspace.

Editing an Existing Calculation

Note:

Only workspace administrators can edit calculations.

To edit an existing calculation:

  • Click on the calculation in the list to view it.
  • Click the edit button in the calculation actions menu.
  • Modify the calculation name, formula, or format as needed.
  • Click the save button to save changes.

Important Considerations

When editing a calculation that is already in use:

  • The calculation shows the number of dashboards using it.
  • Changes to the calculation will affect all dashboards that use it.
  • Consider the impact on existing dashboards before making changes.

Note:

Calculations that are in use cannot have their name changed. To rename a calculation that is in use, it must first be removed from all dashboards using it.

Deleting a Calculation

Note:

Only workspace administrators can delete calculations.

To delete a calculation:

  • Click on the calculation in the list to view it.
  • Click the delete button in the calculation actions menu.
  • Confirm the deletion when prompted.

Note:

Calculations that are in use (shown by a dashboard count greater than zero) cannot be deleted. Remove the calculation from all dashboards before deleting it.

Saving Changes

After creating or editing a calculation:

  • Click the save button to persist changes.
  • A confirmation message is displayed upon successful save.
  • The calculation is immediately available for use in dashboards.

If there are unsaved changes:

  • The interface indicates that the calculation has unsaved changes.
  • Navigating away or selecting another calculation prompts to save or discard changes.

Best Practices

  • Use Descriptive Names - Give calculations clear, meaningful names that describe what they calculate (e.g., "Gross Margin %" instead of "Calc1").
  • Document Complex Formulas - For complex calculations, consider adding comments or documentation outside the system to explain the business logic.
  • Minimize Changes to In-Use Calculations - Be cautious when modifying calculations that are already used in multiple dashboards.
  • Regular Review - Periodically review calculations to ensure they are still needed and accurate.