I am estimating $\theta$, where $\theta=\int_0^1 f(x)dx, \ \text{where}\ f(x)=x*e^{x/2}$

From a unifrm distibution I generate 1000 random numberers from 0 to 1, $x_1,x_2,...x_{1000},$.

$\hat{\theta}= 1/1000 * \sum_{i=1}^{1000}f(x_i) $

Henc, I am taking the average.

How do I construct a Confidence Interval for $\hat{\theta}$? Say 95%.

As far as I can read from Wikipedia, I think my method is called Monte Carlo integration but I am not sure.

  • 3
    $\begingroup$ You could be much more sure by searching our site. Regardless, how would you obtain a confidence interval for the mean of any thousand numbers and why don't you use it here? $\endgroup$ – whuber Jun 13 '17 at 17:45

Expanding on whuber's comment.

The way you make a confidence interval in this case is the same as any.

You have $X_1, X_2, \dots, X_n$ from a Uniform$(0,1$). You have a function $y = g(x) = xe^{x/2}$, so that $Y_1, \dots, Y_n$ are a random sample from a distribution with mean $\theta$ and some unknown variance $\sigma^2$. Once you take the Monte Carlo average, the central limit theorem kicks in and in order to make confidence intervals you just have to obtain an estimate of $\sigma^2$.


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.