Descriptions of more (untested) functions that can be typed directly into the calculator's input box...
Counting: fact(n) [compute n factorial, n!];
choose(n,k) [compute binomial coefficient nCk];
perm(n,k) [compute permutation coefficient nPk];
Especially for larger n... logfact(n) [compute ln(n!)]; logfact(n,b) [compute log(n!,base=b)].
Sample Statistics*: ssize(x) [sample size; i.e., number of values in x];
sum(x) [sum of x values];
mean(x) or avg(x) [sample mean or average of x values];
variance(x) [sample variance of x values];
sd(x) or stdev(x) [sample standard deviation of x values];
mad(x) [mean absolute deviation of x values];
prop(x,q [, direction]) [proportion of values in x that are <= q (when 'direction' arg omitted) or...
for = q, >= q, < q, or > q, add the optional 'direction' argument '=', '>=', '<', or '>')],
e.g., prop(x,23.5,'=') gives proportion of x values equal to 23.5;
min(x) [minimum of values in x];
max(x) [maximum of values in x];
quantile(p,x) or quant(p,x) [compute pth quantile of data x using Excel's percentile()=percentile.inc() formula];
median(x) [sample median of x values];
iqr(x) [interquartile range of x values];
range(x) [max(x)-min(x)].
*In these functions, x is a string of comma-separated numbers,
e.g., in the input box, enter 'mean("1,2,3")' (but without the outside single quotes).
Alternatively, first create a string of comma-separated numbers, then apply a summary statistic formula,
e.g., enter 'x=rnorm(0,1,25)' and then enter 'sd(x)' .
Generate Random #'s:
runi() [generate an observation from Unif(0,1), the continuous Uniform(0,1) distribution];
runi(a,b [,N]) [generate N observations from Unif(a,b); if optional arg N is dropped, it is set to 1];
rnorm(mean,sd [,N]) [generate N from Normal(mean,sd)];
rexp(mean [,N]) [generate N from Expon(mean)];
rgam(shape,scale [,N]) [generate N from Gamma(shape,scale)];
rchisq(df [,N]) [generate N from ChiSq(df)];
rt(df [,N]) [generate N from Student's t(df)];
rduni(a,b [,N]) [generate N from discrete U{a,..,b}];
rbin(n,p [,N]) [generate N from binom(n,p)];
rgeo(p [,N]) [generate N from Geom(p,#trials)];
rpoi(mean [,N]) [generate N from Poi(mean)];
rdice(n [,N]) [roll n six-sided dice N times, record total updots each time];
rdiscrete(v,p [,N]) [generate N from Discrete(v,p), where v are the possible values and p are the probabilities;
here, v and p are strings of comma-separated numbers; e.g., submit rdiscrete("0,5,10","0.2,0.3,0.5",500).
Generate Averages: ravguni(a,b,N) [gen avg based on N from Unif(a,b)], ravgnorm(mean,sd,N) [gen avg based on N from Normal(mean,sd)], ravgexp(mean,N) [gen avg based on N from Expon(mean)], ravggam(shape,scale,N) [gen avg based on N from Gamma(shape,scale)];
ravgduni(a,b,N) [gen avg based on N from discrete U{a,..,b}], ravgbin(n,p,N) [gen avg based on N from binom(n,p)], ravggeo(p,N) [gen avg based on N from Geom(p,#trials)], ravgpoi(mean,N) [gen avg based on N from Poi(mean)].
Trigonometry: cos(theta) [cosine of radians argument theta], acos(y) [arccos of y in radians],
cosd(deg) [cosine of degrees argument deg], acosd(y)[arccos of y in degrees],..., plus sin() and tan() analogs.
Logarithms: log(x) [compute natural log of x, ln(x)], log(x,b) [compute log of x base b], ...
Constants: pi=Math.PI = π = 3.141592653589793 (approx).
Transformation Trick: To apply a function to each element in a comma-separated string x and store results in t,
enter, e.g., ' arr=x.split(","); arr=arr.map((u) => 10*u+5); t=arr.toString() ' in the input box.
If, e.g., x="1,2,5", then this code would give t="15,25,55".
Change function'10*u+5' and variable names, x and t, as desired.
Author: Joseph B. Lang, Department of Statistics and Actuarial Science, University of Iowa.   08/13/2004 01:24:24 PM -0500 (updated 07/17/2024).
Disclaimer: Use at your own risk. Calculators and functions have not been thoroughly tested. See below for comment on rounding error.
Refreshing this webpage will interrupt a slow or non-responsive calculation. Refreshing will also remove all user-defined objects; this can be useful when the user inadvertently creates an object with the same name as one of the functions in the calculator javascript code.
The basic calculator was built around JavaScript code (c. 2003) from The JavaScript Source https://javascriptsource.com.
Numbers less than 1e-16 are generally treated as 0. There will be round-off errors; specifically, upon hitting Return or the "=" button, numbers will generally be accurate only to the 15th significant digit.
The distribution calculators were written using
JavaScript. The algorithms are based on those found in "Numerical Recipes
in C," 2nd edn. Press, W.H., Teukolsky, S.A., Vetteriling, W.T. and
Flannery, B.P. 1992 (1999 reprint).