labaug26 - Lab 1 Using R Andrew J Womack 1 Estimating the...

Info icon This preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Lab 1: Using R Andrew J. Womack Aug 26, 2011 1 Estimating the Moments of a Mixture Distribution I have three measurement devices which you cannot distinguish. With equal probability, I will hand you a device and ask you to make a measurement. With device one, the measurements would follow a N (0 , 1) distribution. With device two, they would follow a T 4 distribution. With device 3 they would follow a Laplace distribution with scale 1. Devise a way to use random samples to produce a density plot of your possible measurements as well as estimating the standard deviation of the distribution. If you are feeling adventurous, you should also write a function that will generate random samples from the mixture distribution. 2 Function Writing and Sourcing Suppose that the random variable W is the sum of X and Y where X χ 2 3 and Y ∼ P (4). Write a function that will generate values of W . Make sure that the function has one input (number of desired samples) and outputs the appropriate number of samples.
Image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern