Learn R Programming

⚠️There's a newer version (1.8.2) of this package.Take me there.

BacArena

BacArena is an agent based modeling framework for cellular communities.

Existing genome-scale metabolic models can be used to simulate growth and interactions in time and space. In BacArena two well established methods are merged: a) Flux balance analysis to predict the activity of metabolic reactions and b) Agent based modelling in order to provide an environment.

It has been efficiently implemented in R language (with some C++ routines) and is freely available CRAN.

Features:

  • Each organism is represented individually
  • Simulation of >10 different species and thousands of organisms on your desktop computer
  • Diffusion of substances
  • Screening of phenotypes
  • Detection of crossfeeding
  • Chemotaxis
  • Kinetics of reactions
  • Separation of simulation and evaluation
  • Rich evaluation methods (data mining)
  • Reproducible simulations
  • Object oriented implementation
  • Easily expandable due to rule based approach

Installation

  • Install the latest release:

install.packages("BacArena")


- Install the development version:
  ```r
library(devtools)
install_github("euba/bacarena")
  • Special hints for windows user
    • Besides R you need to install Rtools

Quick start

library("BacArena")
openArena()

Documentation

A tutorial is available: Introduction

Issues

Please report bugs, disorders or features you would like to see: Issues

Copy Link

Version

Install

install.packages('BacArena')

Monthly Downloads

61

Version

1.0.1

License

GPL-3

Issues

Pull Requests

Stars

Forks

Maintainer

Johannes Zimmermann

Last Published

January 6th, 2016

Functions in BacArena (1.0.1)

simBac

Function for one simulation iteration for objects of Bac class
chemotaxis

Function for chemotaxis of bacteria to their prefered substrate
growth

Function implementing a growth model of a bacterium
Human-class

Structure of the S4 class "Human"
cellgrowth

Function implementing a growth model of a human cell
checkPhen

Function for checking phenotypes in the environment
getPhenoMat

Function for getting a matrix of phenotypes from the dataset
optimizeLP

Function for computing the linear programming according to the model structure
emptyHood

Function to check if the there is a free place in the Moore neighbourhood
addEval

Function for adding a simulation step
getArena

Function for re-constructing an Arena object from a simulation step
growLin

Function for letting organisms grow linearly
plotCurves

Function for plotting the overall change as curves
createGradient

Change substance concentration patterns in the environment according to a gradient
stirEnv

Function for stirring/mixing the complete evironment
Eval-class

Structure of the S4 class "Eval"
changeOrg

Change organisms in the environment
Substance-class

Structure of the S4 class "Substance"
growExp

Function for letting organisms grow exponentially
diffusePDE

Function for diffusion of the Substance matrix
minePheno

Function for mining/analyzing phenotypes which occured on the arena
simHum

Function for one simulation iteration for objects of Human class
Eval-constructor

plotCurves2

Function for plotting the overall change as curves with maximally distinct colors
Bac-class

Structure of the S4 class "Bac"
flushSubs

Remove all substances in the environment
checkCorr

Function to show correlations of a simulated organism or substrate
changeSub

Change substances in the environment
evalArena

Function for plotting spatial and temporal change of populations and/or concentrations
getSublb

Function for calculated the substrate concentration for every organism
constrain

Function for constraining the models based on metabolite concentrations
statPheno

Function for investigating a specific phenotype of an organism
addOrg

Add individuals to the environment
getPhenotype

Function to extract the phenotype of an organism object
BacArena

BacArena: An Agent-Based Modeling Framework for Cellular Communities
plotTotFlux

Function for plotting the overall change in reaction activity
Bac-Constructor

consume

Function to account for the consumption and production of substances
move

Function for random movement of organisms
extractMed

Function for re-constructing a medium concentrations from simulations
Arena-class

Structure of the S4 class "Arena"
Human-constructor

NemptyHood

Function to check if the there is a free place in the Moore neighbourhood
changeFobj

Function for changing the objective function of the model
Organism-class

Structure of the S4 class "Organism"
dat2mat

Function for transforming the organism data frame to a presence/absence matrix of organisms
selPheno

Function for selecting phenotypes which occured on the arena from specific iterations and species
simEnv

Main function for simulating all processes in the environment
openArena

Start simulation
diffuseR

Function for naive diffusion (neighbourhood) of the Substance matrix
changeDiff

Change substance concentration patterns in the environment
Organism-constructor

Constructor of the S4 class Organism
addSubs

Add substances to the environment
getCorrM

Function to compute and return correlation matrix
Arena-constructor

Substance-constructor

Constructor of the S4 class Substance
findFeeding

Function for investigation of feeding between phenotypes
lysis

Lysis function of organismal cells by adding biomass_compounds to the medium