# How do I get the alpha and beta of a non-central beta distribution from mean and variance in R?

I need to fit a beta-distribution a real data, with a mean of 0 and a standard deviation of 0.17.

I have read that this is possible by using the non-central beta distribution, and I would wlike to scale the standard beta distribution up with 0.33, so that the range is from 0 to 1.33. This new variable should then have a non-central beta distribution.

In R this would look like this:

rbeta(n, shape1, shape2, ncp = 0.33), but shape1(alpha) and shape2(beta) have to be generated from the mean and sd.

Has anyone worked this out in R?

Any help would be much appreciated.

• It is very hard to determine what you are asking. If you truly "scale up" a Beta variable, its range will no longer be $[0,1]$ and so it cannot have a Beta distribution any more. No Beta distribution has a mean of zero and a positive standard deviation. Infinitely many Beta distributions have a given standard deviation. Since the information you supply is inconsistent, please edit your post either to change the numbers to correct ones or explain what you mean by a "beta distribution," in case it is unconventional. – whuber Aug 6 '15 at 12:19
• Thank you for comment. I've edited the original question. Hopefuly this is clearer. – user84264 Aug 6 '15 at 15:03

The original range of the data is $[0, 1]$. If you multiply everything by $1.33$, then the data will range from $[0, 1.33]$.