Learn R Programming

mapfit (version 1.0.0)

map: Create MAP

Description

Create an instance of MAP

Usage

map(size, alpha, D0, D1)

Value

An instance of MAP

Arguments

size

An integer for the number of phases

alpha

A vector of initial probability

D0

An infinitesimal generator without arrivals

D1

An infinitesimal generator with arrivals

Examples

Run this code
## create a map (full matrix) with 5 phases
(param1 <- map(5))

## create a map with specific parameters
(param2 <- map(alpha=c(1,0,0),
              D0=rbind(c(-4,2,0),c(2,-5,1),c(1,0,-1)),
              D1=rbind(c(2,0,0),c(0,2,0),c(0,0,0))))

Run the code above in your browser using DataLab