Questions tagged [exponential-distribution]

Anything related to the exponential probability distribution, i.e. a continuous probability distribution whose probability density function is a one-sided decreasing exponential function.

Anything related to the exponential probability distribution, i.e. a continuous probability distribution whose probability density function is a one-sided decreasing exponential function:

f(x) = ke-kx    if x >= 0

f(x) = 0          if x < 0

where k is a constant.

See Wikipedia page on the exponential distribution.


Tag usage

Questions on should be about implementation and programming problems, not about the statistical or theoretical properties of the technique. Consider whether your question might be better suited to Cross Validated, the StackExchange site for statistics, machine learning and data analysis.

85 questions
62
votes
9 answers

Pseudorandom Number Generator - Exponential Distribution

I would like to generate some pseudorandom numbers and up until now I've been very content with the .Net library's Random.Next(int min, int max) function. PRNGs of this variety are supposed to be using a Uniform distribution, but I would very much…
11
votes
2 answers

How to generate random numbers with exponential distribution (with mean)?

I am trying to generate exponentially distributed random number with mean equal to 1. I know how to get random number for normal distribution with mean and standard deviation. We can get it by normal(mean, standard_deviation), but I don't know how…
Sadiksha Gautam
  • 4,604
  • 6
  • 35
  • 67
9
votes
2 answers

Exponential distribution in Python

What's the easiest way to draw a random number from an exponential distribution in Python?
Jake
  • 283
  • 1
  • 7
  • 14
5
votes
1 answer

How to Plot an exponential distribution of spike times over a histogram of them, in R?

So my question follows the development after my last one. I have been trying to work on getting the spike times as a rastor plot for a spike train. I took a firing rate of 100 and got spike train for 20 trials: The code for that is: fr = 100 dt =…
5
votes
4 answers

Random number generator that generates integers for Java

I want to generate some random integers in Java, but this according to some distribution laws. More specific: I want to generate some random integers for gaussian distribution. I found out only generators which return double results for the…
som86
  • 61
  • 4
4
votes
1 answer

Exponential Distribution Simulation in R

I have the following graph: I am told the following information: (1) vertex A to vertex X is described by an exponential distribution with lambda = 4; (2) vertex A to vertex Y is described by an exponential distribution with lambda = 2.5; (3)…
The Pointer
  • 1,602
  • 5
  • 13
  • 36
3
votes
1 answer

How to fit double exponential distribution using MLE in python?

I am trying to fit a double-exponential (i.e. mixture of two exponential or bi-exp) data using MLE. Though there is no direct example of such a problem, yet I found some hint of using MLE for linear (Maximum Likelihood Estimate pseudocode),…
SCBera
  • 33
  • 1
  • 6
3
votes
2 answers

Does Python's random module have a substitute for numpy.random.exponential?

I've been using Numpy's numpy.random.exponential function for a while. I now see that Python's random module has many functions that I didn't know about. Does it have something that replaces numpy.random.exponential? It would be nice to drop the…
Ram Rachum
  • 71,442
  • 73
  • 210
  • 338
3
votes
1 answer

Matlab: Chi-squared fit (chi2gof) to test if data is exponentially distributed

I guess this is a simple question, but I can't sort it out. I have a vector, the first elements of which look like: V = [31 52 38 29 29 34 29 24 25 25 32 28 24 28 29 ...]; and I want to perform a chi2gof test in Matlab to test if V is exponentially…
3
votes
2 answers

Random integers from an exponential distribution between min and max

I would like to generate random integers on an interval min to max. For a uniform distribution in numpy: numpy.random.randint(min,max,n) does exactly what I want. However, I would now like to give the distribution of random numbers an exponential…
218
  • 1,574
  • 4
  • 23
  • 34
3
votes
1 answer

How do I tell how good my exponential curve fit is in SciPy?

I fit some data using Scipy: param=expon.fit(data) pdf_fitted=expon.pdf(x,loc=param[-2],scale=param[-1]) plot(x,pdf_fitted,'r') hist(data,normed=1,alpha=.3,histtype='stepfilled') And I get a curve that looks like this: How do I check how good the…
Devinity
  • 365
  • 1
  • 4
  • 15
3
votes
1 answer

Smoothing out of rough plots

I want to draw some plots in Matlab. Details: For class 1, p(x|c1) is uniform for x between [2, 4] with the parameters a = 1 and b = 4. For class 2, p(x|c2) is exponential with parameter lambda = 1. Besides p(c1) = p(c2) = 0.5 I would like to draw…
ARAT
  • 700
  • 1
  • 11
  • 32
2
votes
0 answers

How to estimate exponential MLL function + add confidence intervals in R gpplot2?

I'm trying to plot the raw data along with the exponential curve fit and add confidence intervals for maximum likelihood model function in R. My data is stored in df(x.number, y.size). I'm trying to run MLL using the skewfun in R I want to use…
Biotechgeek
  • 1,577
  • 7
  • 23
2
votes
1 answer

Exponential distribution of values between a given range in Python

I have three variables Min=0.29, Max=6.52 and center = 2.10. I wish to create a table that distributes this data into 100 values in a table format in the following fashion: Here, this image can be split into two parts 0 to 50 and 50 to 100. In the…
2
votes
2 answers

Defining exponential distribution in R to estimate probabilities

I have a bunch of random variables (X1,....,Xn) which are i.i.d. Exp(1/2) and represent the duration of time of a certain event. So this distribution has obviously an expected value of 2, but I am having problems defining it in R. I did some…
1
2 3 4 5 6