1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
| Quintiq file version 2.0
| #parent: #root
| StaticMethod DebugShowDistribution (
| String comment,
| ProbabilityDistribution distr
| )
| {
| TextBody:
| [*
| info( comment );
| mean := distr.Mean();
| var := distr.Var();
|
| gran := 0.1;
| nrpoints := 10;
| info( 'mean = ', mean , 'var = ', var );
| for ( i := 1; i <= nrpoints; i++ )
| {
| j := floor( nrpoints / 2 );
| x := mean - gran * (i - j );
| info( 'x = ', x, 'cdf = ', distr.Cdf( x ) );
| }
| *]
| }
|
|