Cancel
Showing results for 
Search instead for 
Did you mean: 

Experiment Manager shows wrong data in the report

Valued Contributor
Valued Contributor

Dear community members,

I created  a variable to calculate the waiting time (let's call it Var_Wait) in queue of every single entity and a table in which all the times of Var_Wait are recorded.

the experiment manager report gives me an average of this variable of 22.08 over 100 simulation runs.

I took all the data from the table, calculated the average with excel, and it gives me 35,5.

 

Do you know what happened?

 

 

6 REPLIES 6

Re: Experiment Manager shows wrong data in the report

Siemens Phenom Siemens Phenom
Siemens Phenom

Hi AlessandroPic,

 

your BoxPlot shows that the sample contains many values 0. Maybe these values are empty cells in Excel. Therefore your average value is greater, since the zeros are not counted.

 

Please check the number of elements in your sample by the Excel function

=COUNT(A1:A100)

Do you get the value 100 ?

 

Regards,

Peter

Re: Experiment Manager shows wrong data in the report

Valued Contributor
Valued Contributor
Hi Peter,
Thank you for the reply;
yes I get 100, there should be no mistake in the excel file.
I will attach the model, so you can see it if you want.

Re: Experiment Manager shows wrong data in the report

Siemens Phenom Siemens Phenom
Siemens Phenom

Hi AlessandroPic,

 

we only must consider the observations of an experiment for a selected output value.

Please insert a Tablefile in your model and a Method with the following code. 

Open the console.

 

 local ResObj := ExperimentManager.detailedResults;
local ExpNo := 2;
Tablefile.delete;
ResObj[7,ExpNo].copyRangeTo({1,1}..{1,*}, TableFile, 5,1);
local t:time := Tablefile.meanValue({5,1}..{5,*});
print t;
print ResObj[1,ExpNo];

 The two printed values must be equal. In this way we can check and understand the Plant Simulation method meanValue.

 

Regards,

Peter

Re: Experiment Manager shows wrong data in the report

Valued Contributor
Valued Contributor

Dear Peter, 

I tried to do as you suggested but nothing happens. I mean nothing is recorded in the tablefile and nothing appears in the console. Im doing a mistake someware. I just creaqted a new method and pasted the code you sent me; then i created a Tablefile.

My model is attached

 

Bests,

Alessandro

Re: Experiment Manager shows wrong data in the report

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor

just change

 

local ExpNo := 2;

 

to

 

local ExpNo := 1;

 

You don't defined experiments, so the statistics table contains only one row.

 

 

Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net

Re: Experiment Manager shows wrong data in the report

Siemens Phenom Siemens Phenom
Siemens Phenom

Hi AlessandroPic,

 

the first output value is Drain.statNumIn of type integer. The mean value has type real.

Therefore you use:

 

local t:real := Tablefile.meanValue({5,1}..{5,*});

After the Experiment study I received 138.41 in the console. The Experiment Manager has same value.

 

Regards,

Peter