question

K ST avatar image
0 Likes"
K ST asked Jason Lightfoot commented

Referencing Global Table data from the Experimenter in ver 2021

I am using the new experimenter to test 2 scenarios using 2 sets(columns) of cycle time data from a global table. The global table is referenced within the processor properties, by referencing the column number in a label on the processor.

In the parameters table, I attempted to create an Option type variable and add the 2 column numbers with On Set > reset Label to select a different column for each scenario.

This approach does not appear to be working in the Experimenter, and I would know if there is a better way to reference and test global table data sets in the options type menu. Thank you for your assistance in advance.


FlexSim 21.0.0
experimenterflexsim 21.0.0
r9cghrifvw.png (46.5 KiB)
rcqzkml6x8.png (21.3 KiB)
ounyhntvvm.png (35.2 KiB)
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

1 Answer

Jason Lightfoot avatar image
0 Likes"
Jason Lightfoot answered Jason Lightfoot commented

Keep in mind that the option is the thing you will select against a scenarios, there are a number of ways to use these tools - which can be confusing.

For example here you could:

  • have the processor read the global table value from the Model Parameters Table
  • set a label on the processor which changes the value read from a global table by the processor
  • have the model parameters set values in the global table.

Attached is an example for for the first case where the process time of a processor is configured like this:

And the parameter options code is for each option this:

return Table("GlobalTable1")[1][param(1)];  //row 1 for option 1 - changes to 2 for option 2

ProcessTimeFromParameterGlobalTableLookup.fsm




· 2
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

K ST avatar image K ST commented ·

Thank you so much, I managed to solved the problem from your answer.^^

Would it be possible to for you to further explain how the Option type in the parameters can be utilized compared to other types?

Secondly, how would more than one argument be used in this window here?

0 Likes 0 ·
mdrixk2xlr.png (15.7 KiB)
Jason Lightfoot avatar image Jason Lightfoot ♦♦ K ST commented ·

From the manual: "Option type values require you to enumerate the set of possible values for this value. Each possiblity is called an option. Each option has a name and a value. The value can be a number, text, or a FlexScript expression. The name is arbitrary. "

The name is arbitrary but is shown in the experimenter variables table under each scenario so it helps you understand how a scenario is configured at a glance. The values can be anything but here they are flexible enough for strings which is where I first used them.

Once you've entered values for argument2 and 3 in that window, you access them in the option code as param(2) and param(3).
0 Likes 0 ·