Skip to content

Demographic profiles ​

A profile pairs a demographic description with explicit behavioral inputs. It contains id, demographics, preferences, availableModes, modePreferences, agendaTemplates, decisionTemplates, and optional presenceTemplate.

Demographic attributes accept strings, finite numbers, booleans, or null. Labels such as age, employment, and income have no hidden behavioral equations. To model students or retirees differently, author different schedules, activity preferences, or permitted transport modes in their profiles. The library does not supply demographic distributions.

Assign population ​

Each cohort declares an ID, profileId, count, and home/gateway placement tags. All members use the referenced profile. Schedule distributions are sampled reproducibly. Multiple cohorts may share a profile while using different placement tags.

An explicit agent supplies its own ID, cohort label, and profileId, plus optional home/gateway assignments, household membership, authored needs, and overrides. Its cohort label groups results; it does not implicitly generate a cohort or select a profile.

Override a profile ​

  • Demographic attributes, activity preferences, and mode preferences merge by key; explicit agent values take precedence. A zero preference disables that activity's weight.
  • Supplied availableModes, resolved agenda, and resolved decisions replace the inherited lists. Empty agenda or decision arrays explicitly suppress those behaviors. Mode lists must contain at least one enabled mode.
  • Missing schedules inherit sampled profile templates. Supplying an explicit agenda also replaces the profile's anchor breaks; author corresponding break decisions explicitly.
  • Entry and exit minutes override the corresponding sampled presence bounds independently.

Invalid profiles, overlapping schedules, unknown or disabled modes, invalid household membership, and conflicting IDs are rejected. Cross-references to facilities are checked when graph, facilities, and scenario are combined for execution.

Inspect the result ​

Every resolved agent includes profileId, effective demographics, preferences, permitted modes, and resolved schedules. Inspect these values to explain the behavior that ran. Saved results preserve them and the complete authored input snapshot.

Households and needs retain their existing explicit contracts. They do not automatically create escort trips, joint schedules, or household negotiation. Physical mobility differences, affordability, and income-based destination equations are not modeled.

Documentation for the grABM library.