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

Currently I have a vector of values $x [v_1,\ldots,v_n]$. I can plot the 1d Gaussian by plotting each point $\exp(-(v_i - \mu)^2/(2\sigma^2))\sqrt{2\pi\sigma^2}\cdots$ This gives me a nice looking normal distribution.. However I am trying to graph two different classes and their respective Gaussian and want to show how their probabilities overlap an how difficult it may be to linearly separate them. I was thinking of using a 2d Gaussian to do this, but I am drawing a blank. The formulas I have been trying $\exp(-( (x_i - \mu_x)/(2\sigma_x^2) + (y_i - \mu_y)/(s\sigma_y^2) ))$ are not giving me the representation I wish.. Or maybe I am just plotting it incorrectly..

Any Ideas?


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

You seem to have drawn a density function. $\mu$ and $\sigma^2$ do not need to be the mean and variance of your values to do this.

So try to draw a second similar curve for the function with the same $v_i$ and slightly different values for $\mu$ and $\sigma^2$. If the two $\mu$s are close enough (depending on the $\sigma^2$s) then there should be a visible overlap. Any value $v$ appearing in the middle of this overlap could reasonbly come from either distribution.

enter image description here

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.