question

Kevin S7 avatar image
0 Likes"
Kevin S7 asked Kevin S7 commented

code error when processing data


@Felix Möhlmann Regards, hello again, I used your code to process and store. At first it worked great but then I entered my actual data that I want in the global table and when I made the labels some values came out as 0. Can you help me correct or what should be wrong? They should all have a label assigned according to my percentage of the table since those are the values I want to work with.

1699588017668.png

Data type.fsm


It should not affect arrivals because I am going to increase it. The pallets that arrive are not fixed. I have to modify them, but what won't change this time are the percentages. Those are my percentages that I stick with. I liked how the table turned out, the count and the way it calculates the percentage, but the only small mistake is that it doesn't label all the values.




FlexSim 23.2.1
tables
1699588017668.png (1.8 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

·
Felix Möhlmann avatar image
0 Likes"
Felix Möhlmann answered Kevin S7 commented

Looks likes its working as intended to me. What were you expecting differently?

You create 66 items while there are 75 types, so obviously not all types are used.

When there are multiple entries with the same values, the code will choose one of the eligible ones at random, to rows might be skipped and only later filled in.

Types with higher percentages will be assigned multiple times before types with low percentage are assigned for the first time, as is to be expected if you want to stay as close to the given values as possible. In your model it takes around 190 items until each value was assigned at least once. Which is still considerably lower than one would expect, since the lowest value only occues in 0.3% (1 in 333) cases. (As I said in the other post, this method creates low percentage types more often than one would expect at the beginning. It also clumps the creation of types with similar percentage values more than a random distribution would.)

· 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.

Kevin S7 avatar image Kevin S7 commented ·

I understand perfectly, apologies, I was confusing, excellent help, what you mentioned is fine, thank you

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.