question

Jason Botha avatar image
1 Like"
Jason Botha asked Jason Botha commented

How to set up Experiments with new graphs and stats collector

maybe-this-is-the-key-to-my-happiness.fsm

Hi there,

Is it possible to add an experiment performance measure that is based off the new Statistics collector/calculated table/new graphs.

I have attached a model where i have used the calculated table to generate a TKM metric (Tons per kilometers) for the vehicles that i am using. I now what to add an average TKM as a performance measure to my experiments.

Is this possible?

I have also done the same thing with a Tracked Variable but it doesnt seem to pull through correctly to the Experiment results.

FlexSim 17.2.1
statistics collectorcalculated tableexperimentexperimentor
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

·
Jordan Johnson avatar image
1 Like"
Jordan Johnson answered Jason Botha commented

In the new statistics system, we don't get performance measures from charts. You will need to get the data another way.

The TrackedVariable method is a good idea, but it isn't quite working the wave you want in the Experimenter. The issue is that to set the number of team members, the dispatcher deletes every connected object, except the first. Then it replicates the first up to the correct number. In your case, the only TE that updates the tracked variable gets deleted.

So how do you use Statistics Collectors and Calculated Tables as performance measures? You can add a standard performance measure. For the code, you can use

Table("MyStatsCollector")[1][1]

or

Table("MyCalcTable")[8][3]

Basically, the idea is just to retrieve a value out of the table. That leaves you to figure out what value to put in the table. In your case, I would add another calculated table, with a query like

SELECT AVG(TKM) FROM StatisticsCollector2 WHERE TKM > 0

This will average the interval values for all objects. Since I am not quite clear on the statistic you want, you may need to modify the query. Note that you should put the update mode on Always. This means that the Calculated Table will update whenever the value is asked for. In your case, that is once, when the performance measure (Table("CalculatedTable3")[1][1]) is evaluated.

· 1
5 |100000

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

Jason Botha avatar image Jason Botha commented ·

Hi @jordan.johnson

Thanks for the answer. I managed to add it into my model and its working great. (Also great job on the stats collector. I am really enjoying working with it.)

Thank you for you help and i hope you have a good day further.

Cheers

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

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