www.delorie.com/gnu/docs/mcsim/mcsim_27.html   search  
 
Buy GNU books!


MCSim User' Manual

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

6.2 Syntax of the simulation definition file

The file starts with a global declaration section followed by a number of Experiment (i.e., simulation) definitions (see section 6.4.1 Experiment definition), eventually enclosed in a Level definition if Markov chain Monte Carlo simulations are to be performed (see section 6.5 Specifying a statistical model). Each Experiment defines simulation conditions, from an initial time (or whatever your dependent variable represents) to a final time. The initial values of model state variables, parameter values, input variables, and which outputs are to print at which times can all be changed in a given Experiment.

The general syntax of the file is the same as that of mod with two differences:

Expressions are not allowed (unlike in the model definition file where they can be used). Similarly, structural change to the model, for instance, addition of a state, input, output or parameter, cannot be done here and must be done in the model description file. The simulation specification file is read until its end is reached, or until an End command is reached.

The general layout of the file is:

 
# Input file (this a comment)
<Global modifications and analysis specifications>
Experiment {
  <Specifications for first experiment>
}
Experiment {
  <Specifications for second experiment>
}
# Unlimited number of experiment specifications
End # Optional End statement. Everything after this line is ignored

For Markov chain Monte Carlo simulations (see section 6.3.6 MCMC() specification), the general layout of the file includes Level definitions:

 
# Input file (this is a comment)
SimType(MCMC);
<Global modifications and analysis specifications>
Level {
  # Up to 10 levels of hierarchy
  Experiment {
    Specifications for first experiment
  }
  Experiment {
    Specifications for second experiment
  }
  # Unlimited number of experiment specifications
} # end Level
End # Optional statement. Everything after this line is ignored

6.3 Global specifications  
6.4 Specifying basic conditions to simulate  
6.5 Specifying a statistical model  
6.6 Analyzing results  
6.7 Error Handling  


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

  webmaster     delorie software   privacy  
  Copyright 2003   by The Free Software Foundation     Updated Jun 2003