Pardon my late response. I am using the formula which gets created by this free simulation add-in
https://www.probabilitymanagement.org/tools-1
The formula is
'=IF( Minimum > Most_Likely, NA(), IF( Most_Likely > Maximum, NA(), IF( Minimum = Maximum, Most_Likely, IF( Random_number < ((...
Thanks Hui.
Re:
In my first sentence I mentioned "Revenue is assumed to follow a defined normal distribution and Costs, a triangular distribution. " Neither are flat, and one is in fact normal.
I am making a simple monte carlo model in Excel, using a Data Table to calculate Profit as Revenue minus Costs, where Revenue is assumed to follow a defined normal distribution and Costs, a triangular distribution.
Right now, each of the two random variable cells refers to its own cell...
Hi, some years ago I got some help creating the code below, which sets chart parameters (scale etc) from values in named worksheet cells. It works great. Except that it does this to every chart on a given worksheet, while now, I only want it to do something to one specific chart, which I've...
Yes indeed, I got confused between the worksheet and vba functions. The corrected code is
iOff = DateDiff("d", dAvgDate, Range("E11")) '+ IIf(iOff >= 0, 1, -1)
[CODE/]
Thanks!
Hi all,
I recently got a book of example models using VBA and while it's gotten good reviews and seems to have some interesting stuff, the first example I played with (attached) doesn't run properly. This is for a simulation of project delays. When I run the following code
Sub...
Mods, how do I edit the title of this thread? I did it with another the other day but can't seem to recall how I did it. I'd like to add "Workaround found"
The formula appears in different ways at different times. What I'm asking about would be part of a larger sub which the user starts with a command button. I think I've found a (maybe not elegant) solution, mentioned in my latest post.
Ok, yes, the above would work, using this method for saying whether there is specific text within a string
https://exceljet.net/formula/cell-contains-specific-text
So I guess this is solved in that I can do what I'd like, although it seems klunky to have to take the extra steps to convert the...
Thanks. I am using Excel 2010. I could send a file but it would only have two cells named CellA and CellB. I realise it's hard to imagine why someone would want to do this. Basically it is prevent a circular referemce. It's a long, irrelevant story. I'd like please to just keep the focus of this...
Ok, I've looked here
https://superuser.com/questions/353635/excel-name-referstorange-how-to-check-if-name-object-refers-to-a-range
and here
https://msdn.microsoft.com/en-us/library/bb209088(v=office.12).aspx
and it seems like a solution can be found using some combination of "instr" and...
I need some suggestions on error-handling help please. This is a rather obscure situation, but trust me, I need to do this.
I have two named cells, "CellA" and "CellB".
The macro enters a formula into CellA. The formula will vary. Basically, the macro must be free to write any formula in...
I wonder if this is even possble...I'm using Excel 2010 if that matters, and also I don't want an xml solution as some users could be on Macs.
Let's say I have a Form spinner control, linked to (i.e. controlling) a cell which must not be typed in.
It makes the linked cell increment by X...
Thank you SO much, that works perfectly and is elegant and clear, now that I see it in terms of OFFSET syantax. I'd been looking quite some time, and this is so useful, thanks again sir!
May I ask two follow up questions, please?
-- How would I add error-handling if the dimensions requested...
Hi, I'm more or less a VBA newbie, I mainly record macros and try to adapt them. I'm not having any luck with something which I would imagine would be quite easy to do. If someone could help me with I would be very grateful, I could use this in many different ways.
The basic idea is being...