Skip to content

Agent Based Model Simulation Framework

0packages depend
4.4Kdownloads / year
–test coverage
11/13flavors OK

Overview

About

A high-performance, flexible and extensible framework to develop continuous-time agent based models. Its high performance allows it to simulate millions of agents efficiently. Agents are defined by their states (arbitrary R lists). The events are handled in chronological order. This avoids the multi-event interaction problem in a time step of discrete-time simulations, and gives precise outcomes. The states are modified by provided or user-defined events. The framework provides a flexible and customizable implementation of state transitions (either spontaneous or caused by agent interactions), making the framework suitable to apply to epidemiology and ecology, e.g., to model life history stages, competition and cooperation, and disease and information spread. The agent interactions are flexible and extensible. The framework provides random mixing and network interactions, and supports multi-level mixing patterns. It can be easily extended to other interactions such as inter- and intra-households (or workplaces and schools) by subclassing an R6 class. It can be used to study the effect of age-specific, group-specific, and contact- specific intervention strategies, and complex interactions between individual behavior and population dynamics. This modeling concept can also be used in business, economical and political models. As a generic event based framework, it can be applied to many other fields. More information about the implementation and examples can be found at https://github.com/junlingm/ABM.

Changes in 0.4.3
  • Fixed a bug that prevented the parsingstate transitions such as list(x="a", y="b")->list("x="A", y="b").
  • Fixed a possible memory leak suggested by valgrind.
  • Use cached gamma random number generators to reimplement newGammaWaitingTime.

From NEWS.md in the release

Install

Health

CRAN checks
2NOTE11OK
Check messages
NOTERd contentsr-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc
Rd files without \usage:
  ‘addAgent.Rd’ ‘clearEvents.Rd’ ‘getAgent.Rd’ ‘getID.Rd’ ‘getSize.Rd’
  ‘getState.Rd’ ‘getTime.Rd’ ‘getWaitingTime.Rd’ ‘leave.Rd’
  ‘newAgent.Rd’ ‘newConfigurationModel.Rd’ ‘newCounter.Rd’
  ‘newEvent.Rd’ ‘newExpWaitingTime.Rd’ ‘newGammaWaitingTime.Rd’
  ‘newPopulation.Rd’ ‘newStateLogger.Rd’ ‘schedule.Rd’
  ‘setDeathTime.Rd’ ‘setState.Rd’ ‘setStates.Rd’ ‘stateMatch.Rd’
  ‘unschedule.Rd’
\arguments should not be documented without \usage.

CRAN check page ↗

Slowest check: 3.5 min · r-devel-windows-x86_64
Status changes
  • NOTE11 OK, 2 NOTENow
  • NOTE12 OK, 1 NOTE2026-07-11
  • OK13 OK2026-05-02
  • NOTE11 OK, 1 NOTE2026-04-25
  • OK14 OK2026-04-22
  • ERROR13 OK, 1 ERROR2026-04-18
Show 5 earlier changesHide 5 earlier changes
  • OK14 OK2026-04-16
  • NOTE13 OK, 1 NOTE2026-03-28
  • OK14 OK2026-03-13
  • ERROR13 OK, 1 ERROR2026-03-12
  • OK14 OK2026-03-10
Advisories

none known

Documentation

In release 0.4.3
READMEYes · 240 wordsVignettesNoNEWSYes · 100% structured · mentions 0.4.3Citation fileNoWebsitenot declared in DESCRIPTION
Help pages
32includes a package overview page
Examples that run
100%4 run in a plain check
Exported functions with examples
10%
Documented parameters
100%
Return-value docs
50%
Help pages citing references
0%

Downloads

4.4K
CRAN downloads in the past year
Rank #7,902 · ~12/day · ~364/mo
Daily download trend is not available in this view yet.
41430 days
1.1K90 days
4.4K1 year
Compare downloads with other packages →
Also on370 r2u23 autocran

Repository

35Stars
10Forks
1Open issues
0Open PRs
9Releases
186Commits
2Commit identities
186 commits · Last activity 2026-08-12 · +2.9% stars, 30d · Default branch at 0.6.99, ahead of CRAN 0.4.3 (checked 2026-10-11)
Responsiveness
How these are sampled
PRs merged (all time)
100%
Median days to close, 50 most recently updated closed issues
0
Median days to close, 50 most recently updated closed PRs
0

Stars over time

2025-09-15 · 292026-09-27 · 35
PracticesBeta

Checks run against github.com/junlingm/abm on 2026-10-11.

No development-tooling practices detected in the upstream repository.

How this is detected·Detection ruleset v3 (2026-09-26)

Dependencies

Declared dependencies
3 external dependencies (excludes base and recommended)

Installing ABM adds 2 packages (1 with compiled code, 1.9 MB of source tarballs). Heaviest: Rcpp 1.8 MB, R6 63 KB.

Depends (0)
none
Imports (2)
LinkingTo (1)
Suggests (0)
none
Enhances (0)
none
Reverse dependencies
0direct
0indirect

Nothing depends on this yet.

People & History

People (1)
Author, Maintainer since 0.2 (2023)
Releases (5)

Pick two releases to compare their code metrics.

  • R
    R 4.6.0 released · 2026-04-24
  • R
    R 4.5.0 released · 2025-04-11
  • 0.4.3Latest
    record
    2025-01-26 · current release · diff ↗
  • 0.4.2
    record
    2025-01-15 · diff ↗
  • R
    R 4.4.0 released · 2024-04-24
  • 0.4.1
    record
    2024-03-14 · diff ↗
  • R
    R 4.3.0 released · 2023-04-21
  • 0.3
    record
    2023-03-24 · diff ↗ ·
    added 4 exports
    addAgent, getAgent, leave, setDeathTime
  • 0.2
    record
    2023-03-10
  • R
    R 4.2.0 released · 2022-04-22

Package metadata

First published
2023-03-10
Total releases
5 / 3 yrs
License
GPL (>= 2) OSI
Download size
47 KB

Cite

Cite this package

Run in R for the authors' preferred citation:

citation("ABM")
Ma, J. (2025). ABM: Agent Based Model Simulation Framework (Version 0.4.3) [Computer software]. https://doi.org/10.32614/CRAN.package.ABM

This package has no citation file, so citation() returns this entry built from DESCRIPTION.

Cite the R Observatory

For a number measured here: a download total, a coverage figure, an archival date.

APA

Balamuta, J. J. (2026). R Observatory: Metrics for ABM version 0.4.3 [Data set]. HJJB, LLC. Data release v2026-10-18. https://doi.org/10.5281/zenodo.21843040

From data release v2026-10-18, which the citation names so these numbers can be found later. More on citing and the projects behind them.

Report a problem with this page →

Privacy choices

These apply to this browser and are stored on this device only. Nothing about your choice is sent to us.

Read the privacy policy