How to obtain exponential equation parameter from probplot function?

2 次查看(过去 30 天)
Hello everybody,
I have my dataset that here we name data. It is a vector.
I apply the probplot function from an exponential distribution
h=probplot('exponential',data)
I would like to obtain the exponential parameters to build an exp equation such as
f(x) = a*exp(b*x)
which represents the exponential fit for my data.
Thank you.

采纳的回答

Akira Agata
Akira Agata 2019-5-29
I believe fitdist function should be some help.
  2 个评论
fransec
fransec 2019-5-29
Unfortunately, fitdist doesn't solve my request.
I explain better my issue.
This is my exponential probabilistic plot.
figure,probplot('exponential',data)
exp probplot.jpg
I would like to find the function (or equation) of the reference black dashed line that represents the theoretical exponential distribution, in order to work on data that diverge from that line.
Akira Agata
Akira Agata 2019-5-30
If my uderstanding is correct, you have data vector (e.g N-by-1 array) data, and want to estimate exponential distribution parameter a and b in the equation f(x) = a*exp(b*x).
It seems that the following is one possible step to estimate a and b.
% Sample data (e.g 1000-by-1 array)
pd = makedist('Exponential','mu',2);
data = random(pd,1000,1);
% Estimate parameter mu in f(x) = (1/mu)*exp(-x/mu)
pd2 = fitdist(data,'Exponential');
mu = pd2.mu;
% Since a = (1/mu) and b = (-1/mu),
a = 1/mu;
b = -1/mu;

请先登录,再进行评论。

更多回答(1 个)

Jeff Miller
Jeff Miller 2019-5-30
For a standard exponential distribution,
probability = 1 - exp(-lambda*x)
where x is the data value and lambda is the parameter of the exponential. I think this is the equation of the black dashed line that you show. (But maybe you some other distribution in mind since you show a function with two parameters, a and b).
The value of lambda used in the previous equation would usually be the maximum likelihood estimate:
lambda_est = 1 / mean(data);
So, your graph makes it look like your data set is more compressed at the high end than would be expected from a true exponential.
  1 个评论
fransec
fransec 2019-5-30
Yeah, I think the equation that you proposed represents the black dashed line.
I think that lambda could be 1/mu.
The problem is that I don't know how to plot the probability equation (in plot) over the probability plot, in order to find the intrsection between the two functions...

请先登录,再进行评论。

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by