| Literature DB >> 28989704 |
Abstract
This software implements a discrete time Markov chain model, used to model transitions between states when the transition probabilities are known a priori. It is highly configurable; the user supplies two text files, a "state transition table" and a "config file", to the Perl script genesis.pl. Given the content of these files, the script generates a set of C++ classes based on the State design pattern, and a main program, which can then be compiled and run. The C++ code generated is based on the specification in the text files. Both multiple branching and bi-directional transitions are allowed. The software has been used to model the natural histories of colorectal cancer in Mexico. Although written primarily to model such disease processes, it can be used in any process which depends on discrete states with known transition probabilities between those states. One suitable area may be in environmental modelling. A test suite is supplied with the distribution. Due to its high degree of configurability and flexibility, this software has good re-use potential. It is stored on the Figshare repository.Entities:
Keywords: C++; Markov chain; Markov process; Perl; disease progression; modelling; probabilities; random number generation; simulation; state machine; state transitions
Year: 2017 PMID: 28989704 PMCID: PMC5627703 DOI: 10.5334/jors.179
Source DB: PubMed Journal: J Open Res Softw ISSN: 2049-9647
Figure 1Steps to generate the software and results.
Figure 2State diagram based on the example text files.
Figure 3UML class diagram for the example.