On Sat, 10 Apr 2010, Haneef Anver wrote:

Hi all,


I am trying to find the expectation of x^1/2 where x~N(a,b) ( Normal with mean 
a and variance b).
Any feedback would be highly appreciated.

Start by constructing plots of x vs Re(sqrt(x)) and x vs Im(sqrt(x)) for -1 < x < 1. Do it by hand.

With that plot as a hint you will see how to use integrate() to find the answer.

See

        ?integrate

BTW, you can get both the real and imaginary compoenents with one call to integrate().

HTH,

Chuck



Have great day !

Haneef





        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Charles C. Berry                            (858) 534-2098
                                            Dept of Family/Preventive Medicine
E mailto:cbe...@tajo.ucsd.edu               UC San Diego
http://famprevmed.ucsd.edu/faculty/cberry/  La Jolla, San Diego 92093-0901

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to