The Stack Overflow podcast is back! Listen to an interview with our new CEO.

Questions tagged [pdf]

Probability density function (PDF) of a continuous random variable gives the relative probability for each of its possible values. Use this tag for discrete probability mass functions (PMFs) too.

Filter by
Sorted by
Tagged with
149
votes
6answers
77k views

Can a probability distribution value exceeding 1 be OK?

On the Wikipedia page about naive Bayes classifiers, there is this line: $p(\mathrm{height}|\mathrm{male}) = 1.5789$ (A probability distribution over 1 is OK. It is the area under the bell curve ...
109
votes
10answers
69k views

Why does the Cauchy distribution have no mean?

From the distribution density function we could identify a mean (=0) for Cauchy distribution just like the graph below shows. But why do we say Cauchy distribution has no mean?
57
votes
4answers
26k views

What is the reason that a likelihood function is not a pdf?

What is the reason that a likelihood function is not a pdf (probability density function)?
45
votes
4answers
85k views

How do you calculate the probability density function of the maximum of a sample of IID uniform random variables?

Given the random variable $$Y = \max(X_1, X_2, \ldots, X_n)$$ where $X_i$ are IID uniform variables, how do I calculate the PDF of $Y$?
43
votes
3answers
5k views

Are CDFs more fundamental than PDFs?

My stat prof basically said, if given one of the following three, you can find the other two: Cumulative distribution function Moment Generating Function Probability Density Function But my ...
37
votes
3answers
4k views

Intuitive explanation for density of transformed variable?

Suppose $X$ is a random variable with pdf $f_X(x)$. Then the random variable $Y=X^2$ has the pdf $$f_Y(y)=\begin{cases}\frac{1}{2\sqrt{y}}\left(f_X(\sqrt{y})+f_X(-\sqrt{y})\right) & y \ge 0 \\ 0 ...
36
votes
4answers
11k views

Good methods for density plots of non-negative variables in R?

plot(density(rexp(100)) Obviously all density to the left of zero represents bias. I'm looking to summarize some data for non-statisticians, and I want to avoid ...
31
votes
10answers
29k views

Why is the sum of two random variables a convolution?

For long time I did not understand why the "sum" of two random variables is their convolution, whereas a mixture density function sum of $f(x)$ and $g(x)$ is $p\,f(x)+(1-p)g(x)$; the arithmetic sum ...
29
votes
2answers
16k views

Gamma vs. lognormal distributions

I have an experimentally observed distribution that looks very similar to a gamma or lognormal distribution. I've read that the lognormal distribution is the maximum entropy probability distribution ...
24
votes
4answers
10k views

How to determine quantiles (isolines?) of a multivariate normal distribution

I'm interested in how one can calculate a quantile of a multivariate distribution. In the figures, I have drawn the 5% and 95% quantiles of a given univariate normal distribution (left). For the right ...
22
votes
2answers
19k views

Can you explain Parzen window (kernel) density estimation in layman's terms?

Parzen window density estimation is described as $$ p(x)=\frac{1}{n}\sum_{i=1}^{n} \frac{1}{h^2} \phi \left(\frac{x_i - x}{h} \right) $$ where $n$ is number of elements in the vector, $x$ is a ...
22
votes
2answers
70k views

Finding the PDF given the CDF

How can I find the PDF (probability density function) of a distribution given the CDF (cumulative distribution function)?
22
votes
1answer
4k views

How many times must I roll a die to confidently assess its fairness?

(Apologies in advance for use of lay language rather than statistical language.) If I want to measure the odds of rolling each side of a specific physical six-sided die to within about +/- 2% with a ...
22
votes
3answers
2k views

Is there a Bayesian approach to density estimation

I am interested to estimate the density of a continuous random variable $X$. One way of doing this that I learnt is the use of Kernel Density Estimation. But now I am interested in a Bayesian ...
21
votes
1answer
1k views

Marginal distribution of the diagonal of an inverse Wishart distributed matrix

Suppose $X\sim \operatorname{InvWishart}(\nu, \Sigma_0)$. I'm interested in the marginal distribution of the diagonal elements $\operatorname{diag}(X) = (x_{11}, \dots, x_{pp})$. There are a few ...
20
votes
4answers
19k views

“The total area underneath a probability density function is 1” - relative to what?

Conceptually I grasp the meaning of the phrase "the total area underneath a PDF is 1". It should mean that the chances of the outcome being in the total interval of possibilities is 100%. But I ...
20
votes
1answer
34k views

What does the y axis in a kernel density plot mean? [duplicate]

Possible Duplicate: Probability distribution value exceeding 1 is OK? I thought the area under the curve of a density function represents the probability of getting an x value between a range of ...
20
votes
2answers
1k views

Is there an unbiased estimator of the Hellinger distance between two distributions?

In a setting where one observes $X_1,\ldots,X_n$ distributed from a distribution with density $f$, I wonder if there is an unbiased estimator (based on the $X_i$'s) of the Hellinger distance to ...
19
votes
3answers
4k views

How is $\theta$, the polar coordinate, distributed when $(x,y) \sim U(-1,1) \times U(-1,1)$ and when $(x,y) \sim N(0,1)\times N(0,1)$?

Let the Cartesian $x,y$ coordinates of a random point be selected s.t. $(x,y) \sim U(-10,10) \times U(-10,10)$. Thus, the radius, $\rho = \sqrt{x^2 + y^2}$, isn't uniformly distributed as implied by $...
18
votes
4answers
47k views

Difference between histogram and pdf?

If we want to visibly see the distribution of a continuous data, which one among histogram and pdf should be used? What are the differences, not formula wise, between histogram and pdf?
17
votes
5answers
6k views

Does a univariate random variable's mean always equal the integral of its quantile function?

I just noticed that integrating a univariate random variable's quantile function (inverse cdf) from p=0 to p=1 produces the variable's mean. I haven't heard of this relationship before now, so I'm ...
17
votes
3answers
21k views

Do the pdf and the pmf and the cdf contain the same information?

Do the pdf and the pmf and the cdf contain the same information? For me the pdf gives the whole probability to a certain point(basically the area under the probability). The pmf give the probability ...
17
votes
2answers
17k views

Why is the CDF of a sample uniformly distributed

I read here that given a sample $ X_1,X_2,...,X_n $ from a continuous distribution with cdf $ F_X $, the sample corresponding to $ U_i = F_X(X_i) $ follows a standard uniform distribution. I have ...
17
votes
2answers
436 views

What's the distribution of $(a-d)^2+4bc$, where $a,b,c,d$ are uniform distributions?

I have four independent uniformly distributed variables $a,b,c,d$, each in $[0,1]$. I want to calculate the distribution of $(a-d)^2+4bc$. I computed the distribution of $u_2=4bc$ to be $$f_2(u_2)=-\...
16
votes
4answers
4k views

Which to believe: Kolmogorov-Smirnov test or Q-Q plot?

I'm trying to determine if my dataset of continuous data follows a gamma distribution with parameters shape $=$ 1.7 and rate $=$ 0.000063. The problem is when I use R to create a Q-Q plot of my ...
16
votes
3answers
7k views

Why does a Cumulative Distribution Function (CDF) uniquely define a distribution?

I have always been told a CDF is unique however a PDF/PMF is not unique, why is that ? Can you give an example where a PDF/PMF is not unique ?
15
votes
2answers
12k views

Area under the “pdf” in kernel density estimation in R

I am trying to use the 'density' function in R to do kernel density estimates. I am having some difficulty interpreting the results and comparing various datasets as it seems the area under the curve ...
14
votes
2answers
2k views

Does Wolfram Mathworld make a mistake describing a discrete probability distribution with a probability density function?

Usually a probability distribution over discrete variables is described using a probability mass function (PMF): When working with continuous random variables, we describe probability distributions ...
14
votes
3answers
34k views

How to find the mode of a probability density function?

Inspired by my other question, I would like to ask how does one find the mode of a probability density function (PDF) of a function $f(x)$? Is there any "cook-book" procedure for this? Apparently, ...
14
votes
1answer
68k views

How to find/estimate probability density function from density function in R

Suppose that I have a variable like X with unknown distribution. In Mathematica, by using SmoothKernelDensity function we can ...
14
votes
3answers
9k views

How to calculate overlap between empirical probability densities?

I'm looking for a method to calculate the area of overlap between two kernel density estimates in R, as a measure of similarity between two samples. To clarify, in the following example, I would need ...
14
votes
1answer
9k views

Is there an optimal bandwidth for a kernel density estimator of derivatives?

I need to estimate the density function based on a set of observations using the kernel density estimator. Based on the same set of observations, I also need to estimate the first and second ...
14
votes
1answer
8k views

Finding local extrema of a density function using splines

I am trying to find the local maxima for a probability density function (found using R's density method). I cannot do a simple "look around neighbors" method (where ...
14
votes
3answers
5k views

Best way to put two histograms on same scale?

Let's say I have two distributions I want to compare in detail, i.e. in a way that makes shape, scale and shift easily visible. One good way to do this is to plot a histogram for each distribution, ...
13
votes
3answers
18k views

The sum of two independent gamma random variables

According to the Wikipedia article on the Gamma distribution: If $X\sim\mathrm{Gamma}(a,\theta)$ and $Y\sim\mathrm{Gamma}(b,\theta)$, where $X$ and $Y$ are independent random variables, then $X+Y\sim ...
13
votes
3answers
3k views

Where is density estimation useful?

After going through some slightly terse mathematics, I think I have a slight intuition of kernel density estimation. But I am also aware that estimating multivariate density for more than three ...
13
votes
3answers
789 views

Whence the beta distribution?

As I'm sure everyone here knows already, the PDF of the Beta distribution $X \sim B(a,b)$ is given by $f(x) = \frac{1}{B(a,b)}x^{a-1}(1-x)^{b-1}$ I've been hunting all over the place for an ...
13
votes
1answer
756 views

Why does MLE make sense, given the probability of an individual sample is 0?

This is kind of an odd thought I had while reviewing some old statistics and for some reason I can't seem to think of the answer. A continuous PDF tells us the density of observing values in any ...
13
votes
1answer
425 views

Deriving Negentropy. Getting stuck

So, this question is somewhat involved but I have painstakingly tried to make it as straight-forward as possible. Goal: Long story short, there is a derivation of negentropy that does not involve ...
12
votes
1answer
17k views

Pdf of the square of a standard normal random variable [closed]

I have this problem where I must find the pdf of $Y = X^2$. All I know is that $X$ has the distribution $N(0,1)$. What kind of distribution is $Y = X^2$? Same as $X$? How do I find the pdf?
12
votes
3answers
5k views

Closed form formula for distribution function including skewness and kurtosis?

Is there such a formula? Given a set of data for which the mean, variance, skewness and kurtosis is known, or can be measured, is there a single formula which can be used to calculate the probability ...
12
votes
1answer
31k views

How to interpret height of density plot

How should I interpret the height of density plots: For example in the above plot, peak is at about 0.07 at x=18. Can I infer that about 7% of values are around 18? Can I be more specific than that? ...
12
votes
1answer
194 views

What is the name of the density estimation method where all possible pairs are used to create a Normal mixture distribution?

I just thought of a neat (not necessarily good) way of creating one dimensional density estimates and my question is: Does this density estimation method have a name? If not, is it a special case of ...
11
votes
5answers
22k views

How to get ellipse region from bivariate normal distributed data?

I have data which looks like: I tried to apply normal distribution (kernel density estimation works better, but I don't need such great precision) on it and it works quite well. Density plot makes a ...
11
votes
2answers
68k views

How to calculate the expected value of a standard normal distribution?

I would like to learn how to calculate the expected value of a continuous random variable. It appears that the expected value is $$E[X] = \int_{-\infty}^{\infty} xf(x)\mathrm{d}x$$ where $f(x)$ is the ...
11
votes
5answers
2k views

Probability that a continuous random variable assumes a fixed point

I'm in an introductory statistics class in which the probability density function for continuous random variables has been defined as $P\left\{X\in B\right\}=\int_B f\left(x\right)dx$. I understand ...
11
votes
1answer
9k views

Intuitive understanding covariance, cross-covariance, auto-/cross-correliation and power spectrum density

I'm currently studying for my finals in basic statistics for my ECE bachelor. While I think I have the math mostly down, I lack intuitive understanding what the numbers actually mean.(Preamble: I'll ...
11
votes
1answer
7k views

Density of Y = log(X) for Gamma-distributed X

This question is closely related to this post Suppose I have a random variable $X \sim \text{Gamma}(k, \theta)$, and I define $Y = \log(X)$. I would like to find the probability density function of $...
11
votes
1answer
794 views

How to fit an approximate PDF (i.e.: density estimation) using the first k (empirical) moments?

I have a situation where I am able to estimate (the first) $k$ moments of a data-set, and would like to use it to produce an estimation of the density function. I already came across the Pearson ...
11
votes
1answer
2k views

Estimating the slope of the straight portion of a sigmoid curve

I have been given this task and was stumped. A colleague asked me to estimate the $x_{upper}$ and $x_{lower}$ of the following chart: The curve is actually a cumulative distribution, and x is some ...