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

# atoti.array.n_lowest_indices()

### atoti.array.n\_lowest\_indices(measure, /, n)

Return an array measure containing the indices of the *n* lowest elements of the passed array measure.

The indices in the returned array are sorted, so the first index corresponds to the lowest value and the last index to to the n-th lowest value.

### Example

```pycon theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
>>> pnl_table = session.read_csv(
...     TEST_RESOURCES_PATH / "csv" / "pnl.csv",
...     array_separator=";",
...     keys={"Continent", "Country"},
...     table_name="PnL",
... )
>>> cube = session.create_cube(pnl_table)
>>> l, m = cube.levels, cube.measures
>>> m["Bottom 3 indices"] = tt.array.n_lowest_indices(m["PnL.SUM"], n=3)
>>> cube.query(m["PnL.SUM"], m["Bottom 3 indices"])
                          PnL.SUM      Bottom 3 indices
0  doubleVector[10]{-20.163, ...}  intVector[3]{2, ...}
```

* **Parameters:**
  * **measure** (*VariableMeasureConvertible*)
  * **n** (*PositiveInt* *|* *VariableMeasureConvertible*)
* **Return type:**
  MeasureDefinition
