beetle2 wrote:
HI Guys,
I know that this forum is not for homework but I am trying to interpret R
output code.
I was just wondering if someone might be able to help.

Well, if homework, we can only give hints.


I have been given the following.

For (X1,X2) distributed bivariate normal with parameters mu1 = 5.8 mu2 = 5.3 sd1 = sd2 = 0.2

and p = 0.6

That's Greek letter rho, not p, I expect.


The r-code and inpit/output are as follows

input

m <- 5.3 + 0.6*(6.3 - 5.8)
s  <- sqrt(0.2^2*(1-0.6^2))
q  <- seq(5.12,6.08,0.16)

print(rbind(q,pnorm(mean=m,sd=sd=s,q=q)))

output

q 5.1200  5.280   5.44   5.6     5.76     5.92    6.1
   0.0013  0.023   0.16   0.5     0.84     0.98    1

I have been asked to interpret
E[X2|X1 = 6.3] and varE[X2|X1 = 6.3]


I take it that s<- = 0.16 is the standard variation

Standard _deviation_

So I am assuming that varE[X2|X1 = 6.3] = 0.16^2 = .0256

m <- 5.3 + 0.6*(6.3 - 5.8) = 5.6    this the Expected value of E[X+Y]

What makes you think that? E[X+Y] is mu1+mu2.

The m calculation could also have been written

x1 <- 6.3
m <- 5.3 + 0.6*(x1 - 5.8)

Now go back to your text book and read up on the formulas that connect correlation and regression coefficients.



I see from the output that this would be correct because the probability of
5.6 = 0.5


to interpret E[X2|X1 = 6.3] I can't see it in the output.  And I'm not sure
how to find the conditional probabilty from the output.

Any help would be greatly appreciated






--
   O__  ---- Peter Dalgaard             Ă˜ster Farimagsgade 5, Entr.B
  c/ /'_ --- Dept. of Biostatistics     PO Box 2099, 1014 Cph. K
 (*) \(*) -- University of Copenhagen   Denmark      Ph:  (+45) 35327918
~~~~~~~~~~ - (p.dalga...@biostat.ku.dk)              FAX: (+45) 35327907

______________________________________________
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