Ask the SIMUL8 Community

global variable statistics

Created at
in Community support
If I introduce a global data by information store and add this to the KPI, I can view only the last value of the simulation run. How the average (for example as the average number in queue) during the simulation can be introduced in the KPI summary. I Can save every change of the global variable and the time of change in a spreedsheet and compute the value over a simulation; but this is more complex for several global variables to introduce


  • Was this answer helpful?

    There are probably several ways of doing it. If there are certain places in your VL code that the global value is being changed, you can create a subroutine that you can past the value (and name) of the object and this can be recorded in a spreadsheet with the current time.

    You could also create a subroutine that is called at a certain interval and will record the current values of the global items that you are interested in along with the time.
  • Was this answer helpful?

    I need a global variable accessible by all functions. Just the one

    Where in my add on should I place

    my variable = 15


Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Attach file
Attach image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file