Back to Documentation/Tutorial

Tutorial on design of experiments

Goal: define factors and choose an experimental plan method.

Creating new exploration application

Create a new exploration application by clicking on the "New Exploration application" button, and fill the form as follow:

  • Application name: for example "tutorial".
  • description: for example "Predator Prey Model Exploration".
  • author: your name
  • You could add more metadatas using the add button.
  • Achieve the creation by clicking on the "OK" button.

You are now returned on the main window. On the left frame, there is the "Application" frame that contains the basic scheme of your exploration application. This scheme is a hierarchy of processors. On the central frame, there is the "Editor" tab (and if enabled, the "Start Page" tab). "Editor" tab allows to modify properties of the processors. On the right side frame, there are "Output Structure" tab, "Input Structure" tab, "Factors" tab and "Variables" tab. Those items compose the Applicative context of your exploration application. Each frame could be drag and dropped to rearrange them as you want.

Defining factors and design

First of all, we'll define two factors (a and b), those two factors are typed and are defined on a specific domain. Then, we'll define a design. Finally, we'll visualise the factors values on a 2D chart.

Defining factors

Add the first factor by opening the menu "Exploration">"New factor…". It opens "New factor…" dialog box. Fill the form as follow:

  • Name: "a"
  • Units: for example "preys"
  • Description: for example "Cardinality of the prey group"
  • Type of factor: select "QuantitativeDomain"
    • Type: select "class java.lang.Double"
    • Domain: select "RangeDouble"
    • Min: "0"
    • Max: "32"
    • Step: "8"
  • Validate by clicking "OK".
  • Use the previous procedure for creating the second factor "b", which units are "predators", description is "Cardinality of the predator group", and a RangeDouble between 0 and 24 with a step of 6.

Warning! DO NOT USE THE DUPLICATE FEATURE ( #108 ).

Defining design

To explore the dynamic of the populations according to their initial cardinality, we choose to use a complete plan.

  • Edit the Exploration loop property by "Clicking" on the "Exploration_loop" node in the Application frame.
  • Select "CompletePlan" in the list.

Visualising factor values

In order to visualise factor values, we aggregate factors by Editing "factors" in "Variables" frame:

  • Select the "Variables" frame
  • Right click on "factors" variable, and choose "Edit variable…" in the popup menu.
  • Check the "Gathered after the exploration loop" box.
  • Validate by clicking "OK" button.

Now factors will be gather after each loop execution. So we define the "Final_processing" properties as follow:

  • Edit the "Final_processing" content by clicking on the corresponding processor in the "Applications" frame.
  • Use the Grapher by copying and pasting the following code in the "Editor" tab
import org.simexplorer.graph.Grapher
g = Grapher.getInstance()
g.title = "Design"
g.addSeries(factors)

Your first SimExplorer exploration application is ready to be ran, it computes 25 scenarii (couple of factors) and displayu it on a 2D chart.

  • Run the application by clicking on the run button.

You could change the design and observe the consequence on the exploration:

  • Edit the "Exploration_loop" properties by clicking on it in the "Applications" frame.
  • Select "LHSPlan" in the list.
  • Type "32" in the "Number of experiments" field.
  • Rerun the the application by clicking on the run button.

You should visualize picture like that:

You can also print the values of your factors by typing in the "final processing" step "println" instructions, like :

println "a = " + factors.a
println "b = " + factors.b

Retrieve the final content of the application using this file.

logo cemagref

logo iscpif

logo lifegrid

logo region auvergne

logo patres project