Difference between revisions of "Triangular distribution"

Line 2: Line 2:
 
[[Category:Doc Status D]] <!-- For Lumina use, do not change -->
 
[[Category:Doc Status D]] <!-- For Lumina use, do not change -->
  
= Triangular(min,mode,max) =
+
== Triangular(min, mode, max) ==
  
Creates a triangular distribution, with minimum ''«min»'', most likely value ''«mode»'', and maximum ''«max»''''«min»'' must not be greater than ''«mode»'', and ''«mode»'' must not be greater than ''«max»''.
+
Creates a triangular distribution, with minimum «min», most likely value «mode», and maximum «max».  «Min» must not be greater than «mode», and «mode» must not be greater than «max».
 
 
= When to use =
 
  
 +
== When to use ==
 
Use the triangular distribution when you have the bounds and the mode, but have little other information about the uncertain quantity.
 
Use the triangular distribution when you have the bounds and the mode, but have little other information about the uncertain quantity.
  
= Library =
+
== Library ==
 
 
 
Distribution
 
Distribution
  
= Examples =
+
== Examples ==
 
+
:<code>Triangular(2, 7, 10) &rarr;</code>
Triangular(2, 7, 10) → [[Image:Triangular.png]]
 
 
 
= Independent Samples =
 
  
Like all Analytica distribution functions, [[Triangular]] generates independent distributions across any dimensions occuring in the input parameters.  If you want to generate the same triangular distribution independently over additional dimensions, use the ''Over'' parameter, e.g.:
+
:[[Image:Triangular.png]]
  
:[[Triangular]](2,7,10,Over:I,J)
+
== Independent Samples ==
 
+
Like all Analytica distribution functions, [[Triangular]] generates independent distributions across any dimensions occurring in the input parameters.  If you want to generate the same triangular distribution independently over additional dimensions, use the optional «Over» parameter, e.g.:
= Parameter Estimation =
+
:<code>Triangular(2, 7, 10, Over: I, J)</code>
  
 +
== Parameter Estimation ==
 
An approximate, but quick and dirty, method for estimating the parameters of a triangular distribution from sample data is as follows:
 
An approximate, but quick and dirty, method for estimating the parameters of a triangular distribution from sample data is as follows:
''min''  := [[Min]](data,I)
+
:<code>«min» := Min(data, I)</code>
''mode'' := 3 * [[Mean]](data,I) - [[Max]](data,I) - [[Min]](data,I)
+
:<code>«mode» := 3*Mean(data, I) - Max(data, I) - Min(data, I)</code>
''max''  := [[Max]](data,I)
+
:<code>«max» := Max(data, I)</code>
 
 
Note that if your data is obtained from Monte Carlo simulation, you'll need to use [[Max]]([[Sample]](data),Run) and [[Min]]([[Sample]](data),Run) in the above.
 
  
To see why the above is approximate, consider a data set with 100 points.  The smallest data point is expected to occur around the 0.5% fractile, so we end up using a point around the 0.5% fractile as the ''min'', which of course is not the true min of the underlying distribution.  Although some heuristic adjustments to ''min'' and ''max'' can be made in an attempt to compensate, in general a search is required to locate the maximum likelihood estimator (but for a given ''min'' and ''max'' guess, the ''mode'' estimate above based on the ''mean'' can be used, eliminating the need to search over a third parameter as well).
+
Note that if your data is obtained from Monte Carlo simulation, you'll need to use <code>Max(Sample(data), Run)</code> and <code>Min(Sample(data), Run)</code> in the above.
  
= See Also =
+
To see why the above is approximate, consider a data set with 100 points.  The smallest data point is expected to occur around the 0.5% fractile, so we end up using a point around the 0.5% fractile as the «min», which of course is not the true min of the underlying distribution.  Although some heuristic adjustments to «min» and «max» can be made in an attempt to compensate, in general a search is required to locate the maximum likelihood estimator (but for a given «min» and «max» guess, the «mode» estimate above based on the ''mean'' can be used, eliminating the need to search over a third parameter as well).
  
 +
== See Also ==
 
* [[Dens_Triangular]] -- analytic density function
 
* [[Dens_Triangular]] -- analytic density function
 
* [[CumTriangular]] -- analytica cumulative probability function
 
* [[CumTriangular]] -- analytica cumulative probability function
* [[Triangular_10_50_90]], [[Triangular_10_mode_90]]
+
* [[Triangular_10_50_90]]
 +
* [[Triangular_10_mode_90]]
 +
* [[Distribution Densities Library]]

Revision as of 00:45, 27 January 2016


Triangular(min, mode, max)

Creates a triangular distribution, with minimum «min», most likely value «mode», and maximum «max». «Min» must not be greater than «mode», and «mode» must not be greater than «max».

When to use

Use the triangular distribution when you have the bounds and the mode, but have little other information about the uncertain quantity.

Library

Distribution

Examples

Triangular(2, 7, 10) →
Triangular.png

Independent Samples

Like all Analytica distribution functions, Triangular generates independent distributions across any dimensions occurring in the input parameters. If you want to generate the same triangular distribution independently over additional dimensions, use the optional «Over» parameter, e.g.:

Triangular(2, 7, 10, Over: I, J)

Parameter Estimation

An approximate, but quick and dirty, method for estimating the parameters of a triangular distribution from sample data is as follows:

«min» := Min(data, I)
«mode» := 3*Mean(data, I) - Max(data, I) - Min(data, I)
«max» := Max(data, I)

Note that if your data is obtained from Monte Carlo simulation, you'll need to use Max(Sample(data), Run) and Min(Sample(data), Run) in the above.

To see why the above is approximate, consider a data set with 100 points. The smallest data point is expected to occur around the 0.5% fractile, so we end up using a point around the 0.5% fractile as the «min», which of course is not the true min of the underlying distribution. Although some heuristic adjustments to «min» and «max» can be made in an attempt to compensate, in general a search is required to locate the maximum likelihood estimator (but for a given «min» and «max» guess, the «mode» estimate above based on the mean can be used, eliminating the need to search over a third parameter as well).

See Also

Comments


You are not allowed to post comments.