Contact

R.PST Function (Gnumeric)

Statistical Intermediate Gnumeric Gnumeric 1.12.2 (implementation)

Use Gnumeric R.PST with explicit version limits: a fixed-in-source log-probability defect, fractional-df restrictions and the large-df skew-normal approximation.

Verification status: 21 reference, boundary and advanced-check formulas were recalculated with Gnumeric 1.12.57 ssconvert. Saved identities, the blank input and numerical results were independently checked. Gnumeric 1.12.62 was source-checked only. How formula examples are checked

Version-specific log defect: In Gnumeric 1.12.57, the tested nonzero-shape integer-df log calls return ordinary probabilities instead of logarithms. Release 1.12.62 documents a fix, and its source adds the missing return. The newer release was not executed here. For nonzero shape and df>100, both inspected versions use a skew-normal approximation.

Quick answer: =R.PST(0,5,2) gives 0.14758361765 in Gnumeric 1.12.57.

Availability and version history

  • Introduced: Implementation documented in Gnumeric 1.12.2 release notes. Earlier registration history was not established here.
  • Supported in: Gnumeric 1.12.62; no retirement is established.
  • Scope: Desktop Gnumeric with its Statistical Functions From R plugin. English comma-separated formulas are shown.
  • Checked: October 14, 2026. Tables and the named advanced check use 1.12.57 ssconvert. Current 1.12.62 source was inspected; that release was not executed.

What R.PST returns

R.PST is the cumulative function for the standardized skew-t distribution, with lower, upper and log-probability modes. Shape zero delegates to Student t. Nonzero shape uses a recurrence for integer degrees of freedom up to 100, then a skew-normal approximation above that threshold. Versioned function help.

Syntax and arguments

=R.PST(x,degrees_freedom,shape[,lower_tail[,log_p]])

x, degrees_freedom and shape are required. Degrees of freedom must be positive. lower_tail defaults to TRUE and log_p to FALSE. For nonzero shape, fractional df at or below 100 is unsupported by the inspected CDF helper; fractional df above 100 enters the approximation branch.

Brackets mark optional arguments; do not type them. Current worksheet implementation.

Reproducible examples

These self-contained formulas were recalculated natively. The separate reference column evaluates the stated mathematical distribution; discrepancies are preserved and explained rather than treated as successful mathematical results. Source branches and typed native outputs explain the boundary cases. Results are rounded to twelve decimal places, or thirteen significant digits for small nonzero values. This is presentation precision, not a universal accuracy guarantee.

Formula Gnumeric 1.12.57 result Independent mathematical reference
=R.PST(0,5,2) 0.14758361765 0.14758361765
=R.PST(1,5,2) 0.643516606084 0.643516606084
=R.PST(-1,5,2) 0.006734073733 0.006734073733
=R.PST(1,5,-2) 0.993265926267 0.993265926267
=R.PST(1,5,2,FALSE()) 0.356483393916 0.356483393916
=R.PST(1,5,2,TRUE(),TRUE()) 0.643516606084 -0.440807446399
=R.PST(1,5,2,FALSE(),TRUE()) 0.356483393916 -1.031467621093
=R.PST(1,101,2) 0.684408372082 0.682206548866

Practical worksheet

At x=1, df=5 and shape=2, the ordinary lower probability is approximately 0.643516606084 and the upper is 0.356483393916. These ordinary calls agree with independent integration of the skew-t density.

The correct natural logs are approximately −0.440807446399 and −1.031467621093. The 1.12.57 calls with log_p=TRUE instead repeat the positive ordinary probabilities. For this moderate, nonzero ordinary probability, taking LN of the checked ordinary result gives the mathematical log; this is not a general protection against probability underflow.

Advanced interpretation and checks

The 1.12.57 helper computes a logarithm in its fallback branch but omits return, so execution continues into the ordinary recurrence. The inspected 1.12.62 line returns that logarithm. The advanced difference below is therefore approximately 1.084324052483 in the old engine rather than zero.

At df=101, shape=2 and x=1, the engine returns the skew-normal probability 0.684408372082. Independent integration of the finite-df skew-t density gives approximately 0.682206548866. This is an explicit approximation, separate from the log defect. The approximation also inherits the large-shape limitations of R.PSNORM.

The saved advanced-check result for =R.PST(1,5,2,TRUE(),TRUE())-LN(R.PST(1,5,2)) was 1.084324052483.

Boundaries and troubleshooting

The tested nonzero-shape df=2.5 call returns #NUM!, while shape zero at the same df works through Student t. A noninteger df=100.5 enters the skew-normal approximation rather than the unsupported recurrence. These branches must not be summarized as “all positive df behave alike.”

Zero or negative df gives #NUM!. Nonnumeric text gives #VALUE!, empty F5 becomes zero, and wrong arity gives #N/A. At x=0, the mathematical lower probability is 1/2−ATAN(shape)/PI() for every positive df, but the large-negative-shape approximation can still violate it. Treat the source fix as documentary evidence, not a later native test.

F5 is genuinely empty, rather than a cell containing an empty string.

Formula Gnumeric 1.12.57 result
=R.PST(1,2.5,2) #NUM!
=R.PST(1,2.5,0) 0.797969486361
=R.PST(1,100.5,2) 0.684408372082
=R.PST(1,0,2) #NUM!
=R.PST(1,-1,2) #NUM!
=R.PST(0,1,2) 0.14758361765
=R.PST(0,2,2) 0.14758361765
=R.PST(0,101,-20) 0
=R.PST("abc",5,2) #VALUE!
=R.PST(F5,5,2) 0.14758361765
=R.PST(1,5) #N/A
=R.PST(1,5,2,0,0,1) #N/A

Official evidence and checking scope

The worksheet callbacks are unchanged. The PST helper differs by the missing return fixed in 1.12.62; no newer inverse or CDF execution is inferred. Both stale and uncached SUM controls recalculated correctly. Native XML preserves the R.* identities. The secondary ODF export keeps these calls in the ORG.GNUMERIC namespace; it does not establish execution in another product. GUI entry, other locales and other spreadsheet products were not tested.

R.PT, R.DT, LN.