0
$\begingroup$

How do I simulate Cauchy distribution from Uniform distribution in (-pi/2, pi/2) in R? Not allowed to used any functions that already exist in R that generate Cauchy

$\endgroup$
0
$\begingroup$

You can do something that is called Inverse transform sampling, where you can use uniform distribution to generate other distribution that you want to obtain. It is really good to be familiar with this tool.

http://www.columbia.edu/~ks20/4404-Sigman/4404-Notes-ITM.pdf - it can be helpful for the first steps in this field.

When you generate this distribution, you can apply the result in your R environment.

$\endgroup$
  • $\begingroup$ I have done this and I've shown that c*tanU where U follows the uniform distribution in (-pi/2, pi/2) follows cauchy $\endgroup$ – V.E Oct 11 '18 at 7:57
  • $\begingroup$ Then you can generate n random numbers from uniform distribution and bring it to your new function related to the Cauchy distribution and then you have random numbers from Cauchy distribution. $\endgroup$ – FNTE Oct 11 '18 at 8:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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