> ## Documentation Index
> Fetch the complete documentation index at: https://private-7c7dfe99-mintlify-3a82795f.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

> The result is equal to the square root of varSamp. Unlike this function uses a numerically stable algorithm.

# stddevSampStable

<h2 id="stddevSampStable">
  stddevSampStable
</h2>

Introduced in: v1.1.0

The result is equal to the square root of [varSamp](/reference/functions/aggregate-functions/varSamp). Unlike [stddevSamp](/reference/functions/aggregate-functions/stddevSamp) this function uses a numerically stable algorithm. It works slower but provides a lower computational error.

**Syntax**

```sql theme={null}
stddevSampStable(x)
```

**Arguments**

* `x` — Values for which to find the square root of sample variance. [`(U)Int*`](/reference/data-types/int-uint) or [`Float*`](/reference/data-types/float) or [`Decimal*`](/reference/data-types/decimal)

**Returned value**

Returns the square root of sample variance of `x`. [`Float64`](/reference/data-types/float)

**Examples**

**Basic usage**

```sql title=Query theme={null}
DROP TABLE IF EXISTS test_data;
CREATE TABLE test_data
(
    population UInt8,
)
ENGINE = Log;

INSERT INTO test_data VALUES (3),(3),(3),(4),(4),(5),(5),(7),(11),(15);

SELECT
    stddevSampStable(population)
FROM test_data;
```

```response title=Response theme={null}
┌─stddevSampStable(population)─┐
│                            4 │
└──────────────────────────────┘
```
