1 / 8

Lecture 2

Lecture 2. Recap. R esults of our survey…. Are we smarter than chimps?. In each of the following pair one country has twice the child mortality rate than the other. Sri Lanka or Turkey Poland or South Korea Malaysia or Russia Pakistan or Vietnam Thailand or South Africa. Answers.

sanjiv
Télécharger la présentation

Lecture 2

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Lecture 2

  2. Recap • Results of our survey…

  3. Are we smarter than chimps? • In each of the following pair one country has twice the child mortality rate than the other. • Sri Lanka or Turkey • Poland or South Korea • Malaysia or Russia • Pakistan or Vietnam • Thailand or South Africa

  4. Answers • In each of the following pair one country has twice the child mortality rate than the other. • Sri Lanka or Turkey • Poland or South Korea • Malaysia or Russia • Pakistan or Vietnam • Thailand or South Africa • Collect data and draw a histogram

  5. Chimps histogram plot(0:5,20*dbinom(0:5,5,.5),type="h",xlab="number of correct answers",ylab="average number of chimps")

  6. What about uncertainty • 1000 classes of chimps simulated. • Classes ordered based on average performance • Will Show: Worst class, 2.5%, 5%, 25% nclass=1000 nchimps=20 nquestions=5 count1=matrix(0,nrow=nclass,ncol=nquestions+1) m1=rep(0,nclass) for (i in 1:nclass){ data1=rbinom(nchimps,nquestions,.5) count1[i,]=tabulate(data1,nquestions+1) m1[i]=mean(data1) } i1=order(m1) i2=order(count1[,1]) par(mfrow=c(2,2)) plot(0:5,count1[i1[1],],type="h",xlab="number of correct answers",ylab="average number of chimps",sub="1:1000") plot(0:5,count1[i1[25],],type="h",xlab="number of correct answers",ylab="average number of chimps",sub="25:1000") plot(0:5,count1[i1[50],],type="h",xlab="number of correct answers",ylab="average number of chimps",sub="50:1000") plot(0:5,count1[i1[250],],type="h",xlab="number of correct answers",ylab="average number of chimps",sub="250:1000")

  7. Chimps histogram

  8. Watch a movie • http://www.gapminder.org/videos/the-joy-of-stats/

More Related