How can I get a distribution with the same mean and variance but different skewness?
- I have the mean, variance and skewness of skew-normal distributed random numbers.
- I have the mean variance and skewness of any di开发者_开发百科stribution of random numbers.
How can I have same mean and variance but different skewness?
I second daroczig's answer.
Also, if your data are all positive, a convenient skewed distribution to work with is the gamma. It has two parameters, shape and scale. The mean is shape*scale and the variance is shape*scale*scale. So to match your mean and variance, set the scale of the gamma equal to the ratio of your variance to your mean. Then once you have the scale, set the shape to the mean divided by the scale.
If your question is "how is it possible" to get different skewness:
As the first variable is a normal distribution, which is a symmetric one, while the other could be anything (e.g.: beta distribution), it is possible, that the second variable is assymetric, which makes the skewness differ of course, which measures the asymmetry of a variable.
If your question is "how can it be done" to get different skewness:
Generate an assymetric distribution with given mean and variance, so you will get a variable with the same mean and variance, but with different skewness. E.g. generate a beta distribution with
and shapes in mind that the mean and variance of the generated variable will be around:Of course any other assymetric distribution will work.
精彩评论