+ Reply to Thread
Results 1 to 3 of 3

Thread: Hypergeometric distribution appears to have hidden problems

  1. #1
    Points: 109, Level: 2
    Level completed: 18%, Points required for next Level: 41

    Location
    Port Elizabeth, South Africa
    Posts
    8
    Thanks
    4
    Thanked 0 Times in 0 Posts

    Hypergeometric distribution appears to have hidden problems




    When I was writing a computer program to calculate hypergeometric distributions probabilities I had some funny results. This is because I just used the condition I found in a stats book. The book says: p(x) = formula with x =0;1;....;n where n is the size of the sample drawn and p(x) = 0 otherwise. I stuck this condition into my computer program and had some funny results until I started wondering if the single condition was adequate. If you have a red balls and b white balls and you draw n balls from this set, then obviously n must be less than a+b because there are only a+b balls. Say taking out a red ball is success. Now obviously p(x) must have x less than or equal to a because you cannot have a probability of drawing more than a red balls (or p=0 if you like).
    NOW: If on n draws you have x red balls drawn the rest (n-x) must be white balls.
    Now you have to satisfy the condition that n-x (number of white balls drawn) is less than or equal to b (there are only b white balls). After I stuck in all these conditions I started to have success. To analyse: (n-x)<=b means that when x=0 then (n-0)<=b.
    When x=a then (n-a)<=b. If you stick all these sorts of conditions into the program it works. Seems to me programming gets you thinking of all the necessary conditions, and I would like to add to the conditions given in stats books re the hypergeometric distribution. Anyone agree?
    Last edited by Swayseker; 08-01-2015 at 01:04 PM.

  2. #2
    Devorador de queso
    Points: 95,540, Level: 100
    Level completed: 0%, Points required for next Level: 0
    Awards:
    Posting AwardCommunity AwardDiscussion EnderFrequent Poster
    Dason's Avatar
    Location
    Tampa, FL
    Posts
    12,930
    Thanks
    307
    Thanked 2,629 Times in 2,245 Posts

    Re: Hypergeometric distribution appears to have hidden problems

    Are you positive those conditions aren't stated in one way or another in your book?
    I don't have emotions and sometimes that makes me very sad.

  3. #3
    Points: 109, Level: 2
    Level completed: 18%, Points required for next Level: 41

    Location
    Port Elizabeth, South Africa
    Posts
    8
    Thanks
    4
    Thanked 0 Times in 0 Posts

    Re: Hypergeometric distribution appears to have hidden problems


    It is not specifically stated that n-x must be less than or equal to b. Obviously the probability of (n-x)>b is zero.
    Last edited by Swayseker; 08-03-2015 at 08:17 AM. Reason: spelling

+ Reply to Thread

           




Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts






Advertise on Talk Stats