Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have the Epanechnikov kernel that looks like this:

$$K(x) = \frac{3}{4} * (1 - x^2)$$

I have added $\sigma$ to the equation so that I can adjust the width, very much like the gaussian kernel.

It looks like this:

$$K(x) = \frac{3}{4} * \left(1 - \left(\frac{x}{\sigma^2}\right)^2\right)$$

Can someone verify that the above equation is correct?

share|cite|improve this question
up vote 3 down vote accepted

A kernel is suppose to have a unit integral. You should think of it as a differential:

$$K(x) = \frac{3}{4}(1-x^2) dx.$$

(Of course it is understood the values are $0$ in the complement of the interval $[-1,1]$.)

To change the radius from $1$ to $\sigma$, re-express $x$ as $u / \sigma$:

$$K(u) = \frac{3}{4}(1 - (u/\sigma)^2) d(u/\sigma) = \frac{3}{4\sigma}(1 - (u/\sigma)^2).$$

(Now it is understood $K$ is $0$ in the complement of the interval $[-\sigma, \sigma]$.)

Geometrically this is clear: uniformly stretching the kernel out so it is supported on $[-\sigma, \sigma]$ would multiply its integral by $\sigma$, so you have to rescale its values by $1/\sigma$ to compensate.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.