> ## Documentation Index
> Fetch the complete documentation index at: https://docs.communityhub.cloud/llms.txt
> Use this file to discover all available pages before exploring further.

# Derived Variables: Calculate New Metrics from Existing Data

> Create derived variables in Data Hub that calculate their value from a formula referencing one or more recorded or derived variables.

Data Hub doesn't have a general-purpose data transformation or pipeline builder. Instead, calculated metrics are created as **derived variables** — a variable whose value is computed from a formula referencing other variables, rather than being fed directly by a data source.

## How derived variables work

A derived variable's formula references other variables using a `$variable_name` notation, combined with standard arithmetic operators (`+`, `-`, `*`, `/`). For example:

```text theme={null}
$oberlincity_testbuilding_water_whole_pointa + $oberlincity_testbuilding_water_submeter_pointb
```

Each variable — recorded or derived — has a unique **Data Hub ID**. When writing a formula in the interface, referenced variables are shown by their display name rather than their raw ID, to make formulas easier to read.

A derived variable can reference:

* One or more **recorded variables** (variables fed directly by a data source)
* Other **derived variables**, allowing formulas to build on each other

## Recalculation behavior

Derived variables recalculate automatically whenever a variable they depend on receives a new value. Whether a partial update triggers recalculation depends on how the derived variable is configured:

* If configured to allow partial calculation, the value recalculates as soon as **any** dependency receives a new value — dependencies without a value yet are treated as unavailable rather than blocking the calculation.
* If configured to require all dependencies, the value only recalculates once **every** dependency has a new value.

<Note>
  Calculations run against the highest-resolution data available in Data Hub — minute-level data.
</Note>

## Viewing a derived variable's formula

Every variable's **Details** view shows whether it's a derived variable, and if so, its formula and the variables it depends on. See [Core Concepts](/core-concepts#variables) for more on variable types.

<Note>
  This page covers derived variables as they exist in Data Hub today. There is no separate data pipeline, join, or aggregation feature — if you need to combine or reshape data beyond what a formula-based derived variable supports, use the [Data Downloader or Data API](/api-reference/introduction) to export data for analysis in an external tool.
</Note>
