The Simstack tags and functionalities

This section presents the functionalities for the most common tags used to build the GUI displayed by the WaNos. We also introduce the Test-WaNo example, where the tags below and report are implemented.

1. Variables: Float, Integer, and string

SimStack supports all those variables to represent numbers, strings, and logical terms.

1<WaNoFloat name="var-name" force_disable = "False" description = "describe the meaning of your variable here">float value</WaNoFloat>
2<WaNoInt name="var-name" force_disable = "False" description = "describe the meaning of your variable here">integer value</WaNoInt>
3<WaNoString name="var-name" description = "describe the meaning of your variable here">string</WaNoString>
4<WaNoBool name="var-name" description= "describe the meaning of your variable here">False</WaNoBool>

3. DictBox

WaNoDictBox creates a dialogue box that represents a dictionary of values, and any modifications made by the end-user are changed in the rendered_wano.yml file. Below we show a conditional dictbox, which should be available to the end-user only when the name="var-name-Bool" be set to True.

1<WaNoBool name="var-name-Bool" description= "describe the meaning of your variable here">False</WaNoBool>
2<WaNoDictBox name="var-name" visibility_condition="%s == True" visibility_var_path="var-name-Bool">
3  <WaNoFloat name="var-name 1">float value</WaNoFloat>
4  <WaNoInt name="var-name 2">integer value</WaNoInt>
5  <WaNoString name="var-name 3">string</WaNoS>

4. Multiple Of

The WaNoMultipleOf tag works as a dictbox too and beyond that it allows us to set up directly on the GUI as many variables as needed.

1<WaNoMultipleOf name="var-nanme">
2  <Element id="0">
3    <WaNoString name="string-name">String</WaNoString>
4  </Element>

5. Load files

WaNoFile tag shows a box to define the path to a given selected file.

1<WaNoFile logical_filename="logical file-name"  name="file-name"> file path </WaNoFile>

6. Generating .html reports for the WaNos

Here we show how to creates reports with .html files. In this example (Test-WaNo) the logical_filename="report_template.body" should be defined in the WaNoInputFile tag of Test-WaNo.xml file as shown below.

1<WaNoInputFile logical_filename="report_template.body">report_template.body</WaNoInputFile>

The .html code below shows the setup for the report in the Test-WaNo example.

 2  <h1> Test-Report </h1>
 3<p style="color:blue;font-size:24px;">
 4    The output of this WaNo is the figure.png file; you can download
 5    it to your computer by simply clicking on it in the output folder.
 8<p style="color:blue;font-size:24px;">The inputs of this WaNo are displayed below.</p>
 9{% for key, value in output_dict.items() %}
10  <p style="color:black;font-size:20px;"> {{ key }}: {{value}}</p>
11{% endfor %}
14    <img src="figure.png" alt="RDFs" style="width:65%">
15    <figcaption> <p style="color:red;font-size:24px;">Fig1. - Example of figure.</p>  </figcaption>