IUBio Biosequences .. Software .. Molbio soft .. Network News .. FTP

RESAMPLING SOLUTIONS TO PTOBLEMS

Ghermay Araya asmarina at next03epsl.wam.umd.edu
Thu Sep 30 16:33:54 EST 1993


SOLUTIONS AND PROBLEMS TO PREVIOUS POSTING:


 Resampling, (bootstrapping, etc.), is revolutionizing the practice of  
statistic, and the way it is taught.  For articles, and information on  
software + books, results of classroom trails, and descriptions of pending  
projects in which teachers can become involved, contact the University of  
Maryland's Resampling Project. We are especially interested in class  
testers.  Contact:
	 Resampling Project,
	 attn. P.G. Bruce
	 College of Business
	 University of Maryland,
	 College Park, MD  20742. 
          Phone: 703-522-2713
	 FAX 703-522-5846
	 email pcbruce at wam.umd.edu 
	 
	 (mark attn. P. C. Bruce). 
         please provide  both  postal and email address.



SOLUTIONS:

Solution, Puzzle 1:
        
1.  Three urns - "0,0"; "0,1"; "1,1".
        
2.  Choose an urn at random. [Can do this on the computer 
        
with random selection of urn numbers, and then "If"]
        
3.  Choose the first element in the chosen urn's vector.  If 
        
"1", stop trial and make no further record.  If "0", continue.
        
4.  Record the second element in the chosen urn's vector on 
        
the scoreboard.  
        
5.  Repeat (2 - 5), and calculate the proportion "0s" on 
        
scoreboard. (Answer should be 2/3.)
        
                
        
NUMBERS (1 2 3) a         '"1" denotes a selection of urn 1 (u1),
                          '"2" urn 2, "3" urn 3
NUMBERS (6 6) u1          '"u1" has two pennies (6's)
NUMBERS (7 7) u2          '"u2" has two nickels (7's)
NUMBERS (6 7) u3          '"u3" has one penny & one nickel
REPEAT 1000
  SAMPLE 1 a b            'Select an urn at random
  IF b =1                 'If urn selector says urn 1
    SHUFFLE u1 u1         'shuffle urn 1
    TAKE u1 1 c11         'take one coin from urn 1, call it c11
    IF c11=6              'if the coin is a penny
      TAKE u1 2 c12       'take the second coin
      IF c12=6            'if the second coin is a penny
        SCORE 6 z         'keep track of the second coin result
      END                 'end IF conditions
    END
  END
  
  IF b =2                 'if urn selector says urn 2
    SHUFFLE u2 u2         'etc. as above
    TAKE u2 1 c21
      IF c21=6
        TAKE u2 2 c22
        IF c22=6
          SCORE 6 z
        END
      END
    END
        
    IF b =3
      SHUFFLE u3 u3
      TAKE u3 1 c31
      IF c31=6
        TAKE u3 2 c32
        IF c32=6
          SCORE 6 z
        END
      END
    END
 
END                        'End the experiment, go back and
                           'repeat until 1000 repetitions
                           'are complete
COUNT z = 6 k
DIVIDE k 1000 kk
PRINT kk
        

Answer:        KK       =       0.34



Solution:  Puzzle 2
 
1.  Put a white ball (later have the computer call it "7" to 
        
avoid confusion) or black (call it "8") in the urn with 
        
probability .5.
        
2.  Put in a white and shuffle the two balls.
        
3.  Take out a ball.  If black, stop and make no record.  
        
4.  (If result of (3) is white):  Take out the remaining 
        
ball, examine, and reco


More information about the Dros mailing list

Send comments to us at biosci-help [At] net.bio.net