<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Best way to assign 80+ labels based on percentages? in FlexSim Forum</title>
    <link>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512042#M24902</link>
    <description>&lt;P&gt;Some values are still showing up as 0, can you change the model settings to the decimal places to the amount you want, or are they supposed to be 0?&lt;/P&gt;</description>
    <pubDate>Wed, 06 Mar 2019 22:07:37 GMT</pubDate>
    <dc:creator>joshua_s</dc:creator>
    <dc:date>2019-03-06T22:07:37Z</dc:date>
    <item>
      <title>Best way to assign 80+ labels based on percentages?</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512039#M24899</link>
      <description>&lt;P&gt;&lt;I&gt;[ FlexSim 19.0.0 ]&lt;/I&gt;&lt;/P&gt;&lt;P&gt;I'm working on a decently complicated model and I'm quite new to FlexSim, so all recommendations will be extremely appreciated!&lt;/P&gt;
&lt;P&gt;The most complicated part of my model, so far, has been the high volume of different labels that I would like to use. For the first half of the process that I'm modeling, the incoming items are sent to 1 of 80 different destinations. I have used historical data to determine the percent of time that an item is sent to each particular destination, which ranges from 0 to almost 8%. I tried to put all of these values in a Global Table, but I'm worried that the table is only registering three digits (0.01, for example, when the true value is 0.0058). My first concern is that I will not be able to find a method that can assign values to labels with percentages less than 1 percent.&lt;/P&gt;
&lt;P&gt;The second concern that I have is where to assign these labels, and how exactly to go about that. I have tried to create string labels for each destination that is the 3-character code for that destination, but I haven't quite figured out where those need to be referenced yet. This first part of my model is pretty simple- one source attached to a queue that pushes to a list ("Ready Items"), and processors (represent the 80 destinations) that pull those items from that list. I would like each processor/destination to pull only the items that match the destination assigned at creation.&lt;/P&gt;
&lt;P&gt;Thanks in advanced for any recommendations/advice!&lt;/P&gt;
&lt;P&gt;Edited to add: How should I connect the Global Table (assuming this is the best way to do this) to the list(s) that the queue pushes to and the destinations/sources pull from?&lt;/P&gt;</description>
      <pubDate>Wed, 06 Mar 2019 21:00:18 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512039#M24899</guid>
      <dc:creator>marzanne_dda</dc:creator>
      <dc:date>2019-03-06T21:00:18Z</dc:date>
    </item>
    <item>
      <title>Re: Best way to assign 80+ labels based on percentages?</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512040#M24900</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://answers.flexsim.com/users/13325/marzannedda.html" nodeid="13325"&gt;@Marzanne DDA&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;The answer to your first question is easy.  In the main menu Edit&amp;gt;Model Settings, you can click on the green + icon at the right side of the Decimal Precision field.  That will allow you to edit the number of decimal points that you want in your model.&lt;/P&gt;&lt;P&gt;The second question is really tough to answer specifically without seeing your model or a sample model of the problem area.  Is there anyway you could send us your model or a sample?  If you don't want anyone seeing your model but FlexSim, you can create another question and mark it &lt;A href="https://answers.flexsim.com/articles/24654/how-to-post-confidential-information-on-answers.html"&gt;"Private"&lt;/A&gt;.  That way no one else will be able to see your question but FlexSim employees.&lt;/P&gt;</description>
      <pubDate>Wed, 06 Mar 2019 21:41:11 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512040#M24900</guid>
      <dc:creator>jeff_nordgren</dc:creator>
      <dc:date>2019-03-06T21:41:11Z</dc:date>
    </item>
    <item>
      <title>Re: Best way to assign 80+ labels based on percentages?</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512041#M24901</link>
      <description>&lt;P&gt;I'm glad to hear that there's a simple answer to one of my questions!&lt;/P&gt;
&lt;P&gt;I've attached what I've been working on-- I've been focused on only one of the areas (1HL) that will be covered by this simulation instead of all 5, but I've left the other ones in there since I'm not sure if taking the processors out will affect the Global Table I've created with the percentages. Some of the logic might be kind of a mess because I've been changing and replacing a lot of things to try and find out what works best.&lt;/P&gt;
&lt;P&gt;Thank you for your response!&lt;/P&gt;
&lt;P&gt;&lt;A id="17747" href="https://answers.flexsim.com/storage/temp/17747-deliverymodel.fsm"&gt;deliverymodel.fsm&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 06 Mar 2019 21:56:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512041#M24901</guid>
      <dc:creator>marzanne_dda</dc:creator>
      <dc:date>2019-03-06T21:56:33Z</dc:date>
    </item>
    <item>
      <title>Re: Best way to assign 80+ labels based on percentages?</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512042#M24902</link>
      <description>&lt;P&gt;Some values are still showing up as 0, can you change the model settings to the decimal places to the amount you want, or are they supposed to be 0?&lt;/P&gt;</description>
      <pubDate>Wed, 06 Mar 2019 22:07:37 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512042#M24902</guid>
      <dc:creator>joshua_s</dc:creator>
      <dc:date>2019-03-06T22:07:37Z</dc:date>
    </item>
    <item>
      <title>Re: Best way to assign 80+ labels based on percentages?</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512043#M24903</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://answers.flexsim.com/users/13325/marzannedda.html" nodeid="13325"&gt;@Marzanne&lt;/A&gt; &lt;/P&gt;
&lt;P&gt;This code should work, I don't know where you are planning on putting it, but the variable "Dest" references the processor you want to send the item to. &lt;/P&gt;
&lt;PRE&gt;double randomnum = uniform(0.0, 100.0)*.01;
double total = 0.0;
string Dest;
for (int i=1;i&amp;lt;=Table("Split_BoxPicks").numRows;i++)
{
	total+=Table("Split_BoxPicks")&lt;I&gt;[1];
	if (randomnum &amp;lt;= total)
	{
		Dest=Table("Split_BoxPicks")&lt;I&gt;[2];
		break;
	}
}
return model.find(Dest);
&lt;/I&gt;&lt;/I&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 06 Mar 2019 22:36:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512043#M24903</guid>
      <dc:creator>joshua_s</dc:creator>
      <dc:date>2019-03-06T22:36:42Z</dc:date>
    </item>
    <item>
      <title>Re: Best way to assign 80+ labels based on percentages?</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512044#M24904</link>
      <description>&lt;P&gt;There are two destinations that have values of 0, I kept them in there in Excel in order to compare this type of machinery to another one that delivers to those destinations.&lt;/P&gt;</description>
      <pubDate>Thu, 07 Mar 2019 12:51:17 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512044#M24904</guid>
      <dc:creator>marzanne_dda</dc:creator>
      <dc:date>2019-03-07T12:51:17Z</dc:date>
    </item>
    <item>
      <title>Re: Best way to assign 80+ labels based on percentages?</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512045#M24905</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://answers.flexsim.com/users/8187/joshuas.html" nodeid="8187"&gt;@Joshua S&lt;/A&gt;, I've put this code in with the Send to Port command of the queue, do you know if there's any way to tell if it's actually sending them to the correct destinations instead of randomly? I was also wondering if I needed to change the Pull From List command for each of the processors-- I've edited the input/output logic for each of the processors and attached an updated model.&lt;/P&gt;
&lt;P&gt;Thank you so much for your help with this! After I worked through all of the FlexSim tutorials I thought I had a really good grasp on it, but it's a bit more confusing when you're working from scratch.&lt;/P&gt;
&lt;P&gt;&lt;A id="17760" href="https://answers.flexsim.com/storage/temp/17760-deliverymodel02.fsm"&gt;deliverymodel02.fsm&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 07 Mar 2019 13:55:54 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512045#M24905</guid>
      <dc:creator>marzanne_dda</dc:creator>
      <dc:date>2019-03-07T13:55:54Z</dc:date>
    </item>
    <item>
      <title>Re: Best way to assign 80+ labels based on percentages?</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512046#M24906</link>
      <description>&lt;P&gt;All the processors where pulling items randomly from the List because there was no way of telling the processor which item to pull, also you put the code after the return line in the queue, so it never ran. I changed some things to your model and will show you what other changes need to happen. I added the code to a "On Creation" Trigger in your source, so it gives the item a label and assigns its destination to that label based on the code I previously provided. Then in your list I added another label field so we can query that destination.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="17769-pic2.png"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1498743iD307DEB4EB14F800/image-size/large?v=v2&amp;amp;px=999" role="button" title="17769-pic2.png" alt="17769-pic2.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;now you will have to go to each processor and change its pull logic to the picture below. This will tell the processor pull the item from the list if the items label"destination" matches the processors name.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="17770-pic1.png"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1498744i52A7DAA66BD9C92E/image-size/large?v=v2&amp;amp;px=999" role="button" title="17770-pic1.png" alt="17770-pic1.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&lt;A id="17771" href="https://answers.flexsim.com/storage/temp/17771-17760-deliverymodel02-3.fsm"&gt;17760-deliverymodel02-3.fsm&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 07 Mar 2019 22:21:11 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512046#M24906</guid>
      <dc:creator>joshua_s</dc:creator>
      <dc:date>2019-03-07T22:21:11Z</dc:date>
    </item>
    <item>
      <title>Re: Best way to assign 80+ labels based on percentages?</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512047#M24907</link>
      <description>&lt;P&gt;Also here is a sample model with the data you provided that shows you the distribution based on percentages works. Run the model and look in the table, the last column of each row shows the actual percentage, and it will even out to the value you provided over time.&lt;/P&gt;
&lt;P&gt;&lt;A id="17772" href="https://answers.flexsim.com/storage/temp/17772-test-case.fsm"&gt;test-case.fsm&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 07 Mar 2019 22:23:06 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/best-way-to-assign-80-labels-based-on-percentages/m-p/13512047#M24907</guid>
      <dc:creator>joshua_s</dc:creator>
      <dc:date>2019-03-07T22:23:06Z</dc:date>
    </item>
  </channel>
</rss>

