boozallen / argo

Other
46 stars 19 forks source link

ArgumentOutOfRangeException thrown when creating sensitivity charts #23

Open SLSCHWARTZ1212 opened 6 years ago

SLSCHWARTZ1212 commented 6 years ago

argoerror I am getting the attached error after I run my simulation (using Native Excel) and trying to pull the distribution/Sensitivity analysis for the cell that sums a total of everything. I have it labeled as an RTAresult (running ARGO 4.1.3) and I have not had issues in the past.

Any help is much appreciated.

Thanks.

brandonherzog commented 6 years ago

@SLSCHWARTZ1212 any chance you could provide a sample Excel workbook that reproduces this issue? Thanks!

SLSCHWARTZ1212 commented 6 years ago

@brandonherzog, unfortunately I cannot provide the model due to its sensitivity, but I was able to figure out where the error is coming from. If you use the OPAVERAGE formula, or any of the OP functions it will not produce the charts. Once I took them out, the file worked. Maybe I wasnt using the OP formulas correctly? I used Native Excel to run the model as RTA didnt work due to the complexity. I will say when I used RTA for a smaller trial model to figure out where the problem was RTA gave an error saying "OPAVERAGE is not recognized in Real Times Analytics" or something similar to that message.

brandonherzog commented 6 years ago

@SLSCHWARTZ1212 I'm not sure the exact sequence of events that leads to the initial error (which shouldn't be happening); however, it does sound like the OP functions aren't being used quite correctly. The documentation should be much more explicit about this, but the OP functions can only be used as outputs from your simulation model and never as inputs because they take the entire set of trial results and reduce them to a single statistic.

Or to say it more mechanically: they should only ever reference cells that contain an RtaRESULT or a distribution, and they should never be referenced by cells that contain (or eventually feed into) an RtaRESULT or distribution.

Argo gives you that error in RTA mode because it traces out the entire simulation network and can catch the misuse of OP functions, but in Native Excel mode the tool unfortunately can't always catch it.