actionrwd.segment

actionrwd.segment, function

def process actionrwd.segment(
    timeIndex:  number,
    baseline:   number,
    dispersion: number,
    alpha:      number,
    start:      ranvar,
    duration:   ranvar,
    samples?:   number,
    seed?:      number,
    fixedStart?: number)  : ranvar

Returns the demand ranvar integrated over a segment defined by start and duration, using the same ISSM model as actionrwd.reward.

Examples

table P = extend.range(5)
table S = extend.range(2)

S.Start = dirac(2)
S.Duration = dirac(2)

S.D = actionrwd.segment(
  TimeIndex: P.N,
  Baseline: 10,
  Dispersion: 1.0,
  Alpha: 0.3,
  Start: S.Start,
  Duration: S.Duration)

show table "Segments" with
  S.N
  mean(S.D) as "Mean"

This produces the following table:

N Mean
1 19.99038
2 19.99038

Remarks

Use actionrwd.segment to inspect demand over sub-horizons while keeping the trajectory model aligned with actionrwd.reward.

See also

User Contributed Notes
0 notes + add a note