Question: Consider the following computer experiment. Generate two uniformly distributed numbers x, y in the interval [0, 1] (this is what runif does). Let A be
Consider the following computer experiment. Generate two uniformly distributed numbers x, y in the interval [0, 1] (this is what runif does). Let A be the event that x + y < 1 and B be the event that x y < 0.
(a) Generate 1000 (x, y) values and plot these in R. Create the 1000-length boolean vectors a and b according to whether or not the above events A and B are satisfied. There are 4 possible truth assignments of A and B: {T T, T F, F T, F F}. Use a different plot character for each possible truth assignment. Thus, for example, all of points where both A and B occur would have the same plot symbol, and similarly for the other possible truth assignments. From this picture argue that A and B either are or are not independent
. (b) Using your samples from the first part, compute 95% confidence intervals for P(A) and P(A|B). Are these confidence intervals consistent with A and B being independent?
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
