Questions about random Weibull

Use this forum to post Vensim related questions.
Post Reply
lorenzo.cioni
Senior Member
Posts: 102
Joined: Wed Jul 30, 2014 7:09 am
Vensim version: PLE

Questions about random Weibull

Post by lorenzo.cioni »

Hi everybody
on the Vensim's manual you can read
RANDOM WEIBULL(m,x,S,h,r,s) WEIBULL with shape S starting at 0 with mean 1
and
RANDOM WEIBULL(m,x,S,h,r,s) provides a Weibull distribution with shape S starting at 0 and having a mean of 1 before it is stretched, shifted and truncated. When S is 1 the Weibull distribution is the same as the exponential distribution
and at the beginning of the page that m and x are the minimum and maximum values, respectively, returned by the function.
From all this can we derive m=0?
From all this if by using another sotware I derived that a set of data can be seen as generated by a weibull distribution with parameters alha, beta and gamma how can I match these paramates with the ones above?
Best regards and best wishes.
Lorenzo
Administrator
Super Administrator
Posts: 4573
Joined: Wed Mar 05, 2003 3:10 am

Re: Questions about random Weibull

Post by Administrator »

How are alpha, beta and gamma defined in the other software you are using?
Advice to posters seeking help (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391

Units are important!
http://www.bbc.co.uk/news/magazine-27509559
lorenzo.cioni
Senior Member
Posts: 102
Joined: Wed Jul 30, 2014 7:09 am
Vensim version: PLE

Re: Questions about random Weibull

Post by lorenzo.cioni »

Administrator wrote:How are alpha, beta and gamma defined in the other software you are using?
Hi Administrator
you are right, sorry, I forgot specifying...
alpha shape
beta scale
gamma location parameter

so I would guess
S=alpha
h=gamma
r=beta
Am I right?
Thank you a lot.
Lorenzo
tomfid
Administrator
Posts: 3804
Joined: Wed May 24, 2006 4:54 am

Re: Questions about random Weibull

Post by tomfid »

The Weibull is normally a 2-parameter distribution, so I'm not sure how the gamma/location parameter should be interpreted.

I think S = shape = alpha is a safe bet.

However, the Weibull is often parameterized so that

mean = scale * Gamma( 1 + 1/shape )

whereas Vensim is scaled so that mean = 1. So, you might have to adjust the scale by Gamma( 1 + 1/shape ) to match.
lorenzo.cioni
Senior Member
Posts: 102
Joined: Wed Jul 30, 2014 7:09 am
Vensim version: PLE

Re: Questions about random Weibull

Post by lorenzo.cioni »

tomfid wrote:The Weibull is normally a 2-parameter distribution, so I'm not sure how the gamma/location parameter should be interpreted.

I think S = shape = alpha is a safe bet.

However, the Weibull is often parameterized so that

mean = scale * Gamma( 1 + 1/shape )

whereas Vensim is scaled so that mean = 1. So, you might have to adjust the scale by Gamma( 1 + 1/shape ) to match.
Hi tomfid
sorry for the delay.. thank you.. so you suggest:
S=alpha
h=gamma
r=beta*GAMMA(1+1/alpha)
am I right?
What about m and x in RANDOM WEIBULL(m,x,S,h,r,s) ?
All the best.
Lorenzo
tomfid
Administrator
Posts: 3804
Joined: Wed May 24, 2006 4:54 am

Re: Questions about random Weibull

Post by tomfid »

I would set m and x to 0 and a very large value, unless you want to truncate the distribution.

I think the mean adjustment is correct, but as a test, you should generate a stream of numbers with your proposed distribution, and check them, either with the Stats tool and Bar chart with histogram option on, or by exporting the data to Excel or R or whatever for analysis.
lorenzo.cioni
Senior Member
Posts: 102
Joined: Wed Jul 30, 2014 7:09 am
Vensim version: PLE

Re: Questions about random Weibull

Post by lorenzo.cioni »

tomfid wrote:I would set m and x to 0 and a very large value, unless you want to truncate the distribution.

I think the mean adjustment is correct, but as a test, you should generate a stream of numbers with your proposed distribution, and check them, either with the Stats tool and Bar chart with histogram option on, or by exporting the data to Excel or R or whatever for analysis.
Hi tomfid
now I have a problem with RANDOM EXPONENTIAL....
On the documentation I read
RANDOM EXPONENTIAL(m,x,h,r,s) provides an exponential distribution starting at 0 with a mean of 1 before being stretched, shifted and truncated. So if I have an exponential distribution with parameter alpha I guess it should be

m=0
x=some very high value to avoid truncation
h=0 to avoid shifting
r=1/alpha
s=0

Am I right? I think that the documentation of the rndom function is really horrible, to say the less, and the examples provided are of little help...
Lorenzo
tomfid
Administrator
Posts: 3804
Joined: Wed May 24, 2006 4:54 am

Re: Questions about random Weibull

Post by tomfid »

There are two different parameterizations of the exponential in common use, one with
f(x,a) = a*EXP(-x*a)
and the inverse,
f(x,b) = 1/b*EXP(-x/b)
So, we can't reliably answer without knowing which version your alpha corresponds with.

Assuming that you're expecting a mean of 1/alpha, your suggested parameter choices are correct.
lorenzo.cioni
Senior Member
Posts: 102
Joined: Wed Jul 30, 2014 7:09 am
Vensim version: PLE

Re: Questions about random Weibull

Post by lorenzo.cioni »

tomfid wrote:There are two different parameterizations of the exponential in common use, one with
f(x,a) = a*EXP(-x*a)
and the inverse,
f(x,b) = 1/b*EXP(-x/b)
So, we can't reliably answer without knowing which version your alpha corresponds with.

Assuming that you're expecting a mean of 1/alpha, your suggested parameter choices are correct.
Hi tomfit
thank you.. actually I have to implement a Pareto distribution with parameters

alhpha as shape
beta as scale

and on Wikipedia I found that if I define Y as exponentially distributed with parameter alpha I get beta*exp(Y) as Pareto distributed with those parameters so I am not sure to be able to give you the exact answer.. anyway I tried to set the mean at alpha but I got too high values so I siwtched to 1/alpha and according to what you have said I think that I am right...
Thank you a lot.
All the best.
Lorenzo
grayven87
Junior Member
Posts: 15
Joined: Wed Apr 17, 2019 3:54 pm
Vensim version: PLE

Re: Questions about random Weibull

Post by grayven87 »

Hi everybody

I have a problem regarding the random weibull distribution in vensim, can anybody tell me for which parameters in the distribution description I should enter beta and alpha?
tomfid
Administrator
Posts: 3804
Joined: Wed May 24, 2006 4:54 am

Re: Questions about random Weibull

Post by tomfid »

Terminology for the Weibull distribution is not well standardized, and most sources don't use alpha and beta. Can you give us a reference you're trying to match?
grayven87
Junior Member
Posts: 15
Joined: Wed Apr 17, 2019 3:54 pm
Vensim version: PLE

Re: Questions about random Weibull

Post by grayven87 »

tomfid wrote: Wed Apr 17, 2019 8:03 pm Terminology for the Weibull distribution is not well standardized, and most sources don't use alpha and beta. Can you give us a reference you're trying to match?
well I'm trying to use the function for the weibull distribution that I only have the two following parameters of
alpha , the shape parameter
beta , the scale parameter
tomfid
Administrator
Posts: 3804
Joined: Wed May 24, 2006 4:54 am

Re: Questions about random Weibull

Post by tomfid »

Try the sample model attached to the help system topic for the random functions. It's in c:\users\public\vensim if your OS won't let the help link work.
grayven87
Junior Member
Posts: 15
Joined: Wed Apr 17, 2019 3:54 pm
Vensim version: PLE

Re: Questions about random Weibull

Post by grayven87 »

Hi Tomfid
I had tried the sample model and have also studied and thoroughly read your help page before but I still had the same problem.I think it would be better if you could provide me with some additional information about what the standard parameters of this function in Vensim define.I think that this way I can search for the additional information it requires and try to fill in its parameters.
tomfid
Administrator
Posts: 3804
Joined: Wed May 24, 2006 4:54 am

Re: Questions about random Weibull

Post by tomfid »

Here are three different parameterizations, using terminology from NIST, Wikipedia and Wolfram Mathworld:
RANDOM functions.mdl
(38.93 KiB) Downloaded 267 times
grayven87
Junior Member
Posts: 15
Joined: Wed Apr 17, 2019 3:54 pm
Vensim version: PLE

Re: Questions about random Weibull

Post by grayven87 »

tomfid wrote: Thu Apr 18, 2019 6:16 pm Here are three different parameterizations, using terminology from NIST, Wikipedia and Wolfram Mathworld:
RANDOM functions.mdl

Thanks a lot!! :)
Post Reply