Difference between revisions of "ProbDist - Custom continuous distribution using density points"

m (category custom)
(New to 5.2)
 
(2 intermediate revisions by the same user not shown)
Line 7: Line 7:
 
Use these functions to specify a custom continuous probability distribution by specifying probability density points at selected values.
 
Use these functions to specify a custom continuous probability distribution by specifying probability density points at selected values.
  
== ProbDist(p, r'', I'') ==
+
To use, you need to specify (p_i, r_i) points, where «p_i» is an array of relative non-negative densities indexed by «<code>I</code>» and «r_i» is an increasing array of values, also indexed by «<code>I</code>». The values in «p_i» are relative -- the function normalizes them so that the area under the distribution adds to 1.  
Specifies a customized continuous probability distribution as an array of relative probability densities, «p», at each of corresponding value in array «r».  The values of «r» must be increasing, and the densities in «p» must be non-negative. The values in «p» are relative -- the function normalizes them so that the area under the distribution adds to 1.
+
  
Usually the first and last values in «p» are zero.  If not, it extrapolates out for a distance equal to the spacing between the first two points (or last two points) before reaching zero.
+
It produces a density function using linear interpolation between the specified points on the density function.
  
The arrays «p» and «r» must have a common index, which should be specified as the third parameterSometimes an implicit index is used for «r» or «p», in which case the third parameter is optional.
+
Usually the first and last values in «p_i» are zeroIf not, it extrapolates out for a distance equal to the spacing between the first two points (or last two points) before reaching zero.
  
It produces a density function using linear interpolation between the specified points on the density function.
+
The index parameter «<code>I</code>» can be omitted if either «p_i» or «r_i» is itself an index (in which case the other is an array indexed by that).
 +
 
 +
== Functions ==
 +
=== ProbDist(p_i, r_i'', I, over'') ===
 +
The distribution function. Use this to specify a quantity that has your custom distribution.
 +
 
 +
If you want to define independent and identically distributed quantities along one or more indexes, list those indexes in the optional «over» parameter.
 +
 
 +
=== <div id="DensProbDist">DensProbDist( x, p_i, r_i'', I, over'')</div> ===
 +
''New to [[Analytica 5.2]]''
 +
 
 +
The analytic density function. Computes the probability density at «x» according to your custom distribution, after any normalization has been applied.
 +
 
 +
=== <div id="CumProbDist">CumProbDist( x, p_i, r_i'', I, over'')</div> ===
 +
''New to [[Analytica 5.2]]''
 +
The analytic cumulative density function. Computes the probability that a random outcome is less than or equal to «x».
 +
 
 +
=== <div id="CumProbDistInv">CumProbDistInv( p, p_i, r_i'', I, over'')</div> ===
 +
''New to [[Analytica 5.2]]''
 +
The analytic inverse cumulative density function (aka ''quantile function''). Computes the «p»<sup>th</sup> fractile/quartile/percentile.
  
 
== See Also ==
 
== See Also ==

Latest revision as of 22:41, 10 October 2018


Use these functions to specify a custom continuous probability distribution by specifying probability density points at selected values.

To use, you need to specify (p_i, r_i) points, where «p_i» is an array of relative non-negative densities indexed by «I» and «r_i» is an increasing array of values, also indexed by «I». The values in «p_i» are relative -- the function normalizes them so that the area under the distribution adds to 1.

It produces a density function using linear interpolation between the specified points on the density function.

Usually the first and last values in «p_i» are zero. If not, it extrapolates out for a distance equal to the spacing between the first two points (or last two points) before reaching zero.

The index parameter «I» can be omitted if either «p_i» or «r_i» is itself an index (in which case the other is an array indexed by that).

Functions

ProbDist(p_i, r_i, I, over)

The distribution function. Use this to specify a quantity that has your custom distribution.

If you want to define independent and identically distributed quantities along one or more indexes, list those indexes in the optional «over» parameter.

DensProbDist( x, p_i, r_i, I, over)

New to Analytica 5.2

The analytic density function. Computes the probability density at «x» according to your custom distribution, after any normalization has been applied.

CumProbDist( x, p_i, r_i, I, over)

New to Analytica 5.2 The analytic cumulative density function. Computes the probability that a random outcome is less than or equal to «x».

CumProbDistInv( p, p_i, r_i, I, over)

New to Analytica 5.2 The analytic inverse cumulative density function (aka quantile function). Computes the «p»th fractile/quartile/percentile.

See Also

Comments


You are not allowed to post comments.