Learn R Programming

ABM (version 0.4.1)

newExpWaitingTime: Creates an exponentially distributed waiting time

Description

Creates an exponentially distributed waiting time

Value

an external pointer

Arguments

rate

the rate of the exponential distribution

Details

This function creates an C++ object of type ExpWaitingTime. It can be passed to addTransition or Simulation$addTransition to specify the waiting time for a transition. As a C++ object, it is faster than using an R function to generate waiting times because there is no need to call an R function from C++.