RANDSNORM Function (Gnumeric)
Generate skew-normal variates in Gnumeric with RANDSNORM, optional shape/location/scale parameters and the distinction between parameters and moments.
Verification status: Gnumeric 1.12.57 ssconvert bounded RANDSNORM fixtures only; retained 1.12.62 source inspected separately; no GUI. How formula examples are checked
RANDSNORM generates a random value from a skew-normal distribution. Its shape parameter controls asymmetry, while its location and scale parameters shift and stretch the distribution. With nonzero shape, location is generally not the mean and scale is generally not the standard deviation.
Syntax and defaults
=RANDSNORM([shape[,location[,scale]]])
All arguments are optional in Gnumeric. Shape defaults to 0, location to 0 and scale to 1. Supply arguments in that order; when setting scale, explicitly supply the preceding shape and location. A negative scale produces #NUM!. A zero scale is accepted in the tested build and collapses the output to the location.
Shape zero gives an ordinary normal distribution with the specified location and scale. Positive shape introduces rightward skew and negative shape reflects the asymmetry. The shape value is not itself the conventional skewness coefficient.
The function is volatile and produces a fresh random draw on recalculation. Two cells with identical formulas need not return the same number. No seed argument or repeatable sequence is provided by this function’s syntax.
Worked examples with honest expectations
=RANDSNORM() produces a random standard-normal value. There is no fixed numeric expected output for an individual draw. A bounded native test checked only that it returned a number; it did not certify the whole distribution from one draw.
For a deterministic boundary check, =RANDSNORM(3,10,0) returns 10, because multiplying the random component by zero leaves the location. =RANDSNORM(0,5,0) returns 5. These are degenerate distributions, not examples of nonzero random variation.
=RANDSNORM(0,0,-1) returns #NUM! in the tested build. An invalid negative scale should be corrected rather than hidden as a random zero.
Advanced use: distinguish parameters from moments
Consider =RANDSNORM(3,10,2). Let δ = 3/√10. The theoretical mean is 10+2*δ*SQRT(2/PI()), and the theoretical variance is 4*(1-2*δ^2/PI()). The independently calculated mean is approximately 11.513879513212, and the variance is approximately 1.708168819477. These formulas describe distribution moments, not the next generated value.
An independent way to model the same family is to combine independent standard-normal variables U and V as location + scale*(δ*ABS(U)+SQRT(1-δ^2)*V). This identity explains the positive mean shift for positive shape and the different variance. It is a mathematical comparison, not a promise of identical random streams or the exact internal sampling order.
To explore the distribution, fill a modest sample column with the formula and inspect its mean and spread alongside the theoretical values. A finite sample will vary, and a small sample can look irregular. Preserve the generated values separately if a report needs the same realization later; leaving volatile formulas in place does not freeze the experiment.
Errors and practical cautions
- Negative scale is invalid. Zero scale gives the location in the bounded tests, but it removes all random variation.
- Do not assume location equals mean when shape is nonzero, or scale equals standard deviation.
- Extreme shape values and nonfinite inputs are not certified by the bounded examples here. Use a finite, justified model parameter.
- A random value outside a few standard deviations is not automatically a calculation error. Investigate distributional assumptions and sample size before discarding it.
- Recalculation changes live random samples; chart changes can be expected even when the formula text has not changed.
- This generator is for statistical modeling, not cryptographic secrets or an empirical guarantee that real-world data follow a skew-normal law.
Version and evidence
Official NEWS records RANDSNORM as added in Gnumeric 1.9.15. The retained 1.12.62 callback and random generator support the inspected parameter contract. Native cases below cover deterministic zero-scale/error outputs and type checks for ordinary random calls, not distributional goodness-of-fit or sequence reproducibility. No retirement date is inferred.
Related functions
Official sources
Native verification scope
On 17 October 2026, Gnumeric 1.12.57 ssconvert recalculated 5 bounded RANDSNORM fixture records in C.UTF-8. The recorded outputs matched the independent expectations described here. The random calls were checked only for returning numeric values in that execution; no exact random draw or distributional quality claim follows. This is engine evidence, not GUI or screenshot evidence. Examples using composed helper formulas or affine transformations are mathematical checks unless separately recorded; other versions and untested boundaries remain outside this scope.