BETAINV Function (LibreOffice Calc)
The BETAINV function returns the inverse of the cumulative beta distribution. It is used in Bayesian inference, A/B testing, reliability analysis, and probability modeling.
Compatibility
▾| Excel | ✔ |
| Gnumeric | ✔ |
| Google_sheets | ✖ |
| Libreoffice | ✔ |
| Numbers | ✖ |
| Onlyoffice | ✔ |
| Openoffice | ✔ |
| Wps | ✔ |
| Zoho | ✔ |
What the BETAINV Function Does ▾
- Computes the quantile of a beta distribution
- Supports optional lower/upper bounds
- Useful for Bayesian credible intervals, A/B test thresholds, and bounded probability modeling
- Inverts BETADIST to find the value corresponding to a given probability
Syntax ▾
Standard form (0 to 1)
BETAINV(p; alpha; beta)
Bounded form (a to b)
BETAINV(p; alpha; beta; a; b)
Arguments
-
p:
Probability (0–1). -
alpha:
Shape parameter α (must be > 0). -
beta:
Shape parameter β (must be > 0). -
a (optional):
Lower bound of the interval (default = 0). -
b (optional):
Upper bound of the interval (default = 1).
Basic Examples ▾
Standard beta quantile
=BETAINV(0.95; 2; 5)
→ 95th percentile of Beta(2,5)
Bounded beta quantile
=BETAINV(0.8; 3; 4; 10; 20)
Using cell references
=BETAINV(A1; B1; C1)
Advanced Examples ▾
Bayesian credible interval (upper bound)
=BETAINV(0.95; Successes+1; Failures+1)
A/B test: probability threshold for conversion rate
=BETAINV(0.9; A_success+1; A_fail+1)
Reliability modeling (bounded variable)
=BETAINV(0.99; 3; 4; 10; 20)
Compute central credible interval
=BETAINV(0.975; α; β) - BETAINV(0.025; α; β)
Transform bounded variable to 0–1 scale
=BETAINV(p; α; β; a; b)
Use with BETADIST to verify inversion
=BETADIST(BETAINV(p; α; β); α; β)
Edge Cases and Behavior Details ▾
BETAINV returns a numeric value within [a, b]
Accepts:
- p in [0, 1]
- α > 0
- β > 0
Behavior details
- If p = 0 → returns a
- If p = 1 → returns b
- α and β control skewness and shape
- Default bounds are 0 and 1
- Inversion may be slow for extreme α/β values
Invalid input → Err:502
BETAINV of an error → error propagates
Common Errors and Fixes ▾
Err:502 — Invalid argument
Cause:
- p < 0 or p > 1
- α ≤ 0 or β ≤ 0
- a ≥ b
- Non-numeric input
Fix:
- Clamp p to [0,1]
- Validate α and β
- Ensure a < b
- Convert text with VALUE
Unexpected quantile values
Cause:
- Misinterpreting cumulative vs. inverse
- Using wrong α/β parameters
Fix:
- Confirm α and β definitions
- Use BETADIST to verify
Best Practices ▾
- Use BETAINV for Bayesian credible intervals and quantile analysis
- Validate α and β to avoid domain errors
- Use bounded form for real-world ranges
- Combine with BETADIST for probability checks
- Use differences of BETAINV for interval widths
BETAINV is essential for Bayesian inference, A/B testing, and any model requiring quantiles of a bounded probability distribution.
Related Patterns and Alternatives ▾
- Use BETADIST for cumulative probabilities
- Use BETA for the probability density function
- Use NORMINV, GAMMAINV, and FINV for other inverse distributions
- Use GAMMALN for stable parameter calculations
By mastering BETAINV, you can build powerful statistical, Bayesian, and probability‑driven models in LibreOffice Calc.