Skip to content

Main content

Model State Time Share Tool

Calculate model state time share from explicit caller-supplied inputs.

Loading tool…

Description

Sum all alive duration and alive duration for selectedState, then divide or return zero with defined false.

Health-economic utility models combine time with a supplied valuation scale. The reference anchors, duration units, survival basis, and discount timing determine the interpretation of each utility-year contribution.

Sum all alive duration and alive duration for selectedState, then divide or return zero with defined false.

When to use this tool

Use Model State Time Share when you need one explicit utility or modeled outcome component.

How to use the tool and how it works

  1. Enter stateIds, durations, aliveState, selectedState. Keep parallel arrays aligned. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read aliveTime, selectedAliveTime, share, defined. Inspect defined before interpreting the associated values.

Require aligned stateIds, nonnegative durations, and aliveState flags. Sum all alive duration and alive duration for selectedState, then divide or return zero with defined false.1

Input fieldMeaning and unitsAccepted input
stateIdsState IdsRequired. Array of text; maximum UTF-16 length 8192; maximum items 256.
durationsDurationsRequired. Array of finite number; minimum 0; maximum items 256.
aliveStateAlive StateRequired. Array of boolean; maximum items 256.
selectedStateSelected StateRequired. Text; maximum UTF-16 length 8192.
Output fieldInterpretationReturned shape
aliveTimeAlive TimeRequired. Finite number.
selectedAliveTimeSelected Alive TimeRequired. Finite number.
shareDimensionless share under the stated denominator and exclusion convention.Required. Finite number.
definedWhether the associated ratio has its required denominator; inspect before using a zero placeholder.Required. Boolean.
json
{
  "input": {
    "stateIds": [
      "A",
      "B",
      "D"
    ],
    "durations": [
      2,
      3,
      5
    ],
    "aliveState": [
      true,
      true,
      false
    ],
    "selectedState": "A"
  },
  "output": {
    "aliveTime": 5,
    "selectedAliveTime": 2,
    "share": 0.4,
    "defined": true
  }
}

Limitations and assumptions

  • The denominator excludes records marked not alive; duplicate state rows contribute separately and the supplied model does not verify survival or a valid state-transition history.
  • Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
  • Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.

Alternative or Complementary methods

Check the complete evaluation model and source valuations; arithmetic utility values are not individual clinical assessments or judgments of personal worth.

References

  1. Calculation and input contract: health-economics/model-state-time-share — tool.io

Similar or alternative tools