Hello, please help me with R programming. The answers have to be in…
Question Answered step-by-step Hello, please help me with R programming. The answers have to be in… Hello, please help me with R programming.The answers have to be in R coding form!! 0.2 Part 1: Trick Coin?My brother claims to have a trick coin that comes up heads 60% of the time and comes up tails 40% of the time. I flipped the coin 100 times and got heads 50 times and tails 50 times. Do the results of my coin flips disprove my brother’s claim about the odds or is the difference between my results and his claim simply due to randomness? In this section, we will use p-values to answer this question. 0.2.1 Question 1: Measured distanceCompute the distance between the odds that my brother claims and the odds that I observed when flipping the coin. Store this number in the variable measured_distance. 0.2.2 Question 2: Simulate coin flipsSimulate running 5000 trials of flipping the a trick coin like my brother described 100 times. For each trial, compute the proportion of the flips that came up heads, the proportion that came up tails and the distance between the odds observed in the trial and the odds described by my brother. Be careful to use the same method for measuring distance that you used in exercise 1. 0.2.3 Question 3: Find the p-valueUse the summarized data from the previous exercise to compute the p-value for the distance mea- sured in exercise ??. What do you concluded based on the p-value? Is the difference between my coin flips and my brothers description due to randomness or something else? Computer Science Engineering & Technology Python Programming COMPTNG MISC Share QuestionEmailCopy link Comments (0)


