This paper circulates around the core theme of The following BASIC code generates 10,000 values of a random variable X and calculates the sample average together with its essential aspects. It has been reviewed and purchased by the majority of students thus, this paper is rated 4.8 out of 5 points by the students. In addition to this, the price of this paper commences from £ 36. To get this paper written from the scratch, order this assignment now. 100% confidential, 100% plagiarism-free.
The following BASIC code generates 10,000 values of a random variable X and calculates the sample average, the sample variance, and the fraction of sample values that lie in the interval (a, b]. Adapt this simulation program (you may use BASIC or any other language) to: 1. Calculate the values needed to fill in the table for E(X), V(X) and Xb) P(a ≤ < , where a and b are specified in Homework 0. Show all theoretical calculations. 2. For each case, on a separate page, draw the graph of the theoretical distribution function Fx(t), fill in the table describing Fx(t), and plot the simulation values given in the table on the same graph as the theoretical distribution function.
100 FOR i = 1 TO 10000
200 S1 = S1 + X 300 S2 = S2 + X^2 400 IF (X > a) AND (X <= b) THEN c = c + 1 500 NEXT i 600 PRINT S1/10000, S2/10000 –(S1/10000)^2, c/10000