Wednesday, February 5, 2014

Yo Bayes, what was that bird?

Let's say you're out birding and see a bird and you think it might be a "goodie" - a species that's rarely encountered but you're not entirely sure. Is there a way to estimate the probability of correctly identifying the bird?

Yup.

This is what you'll need:

1. The number of alternatives

  • For example, a small yellow-green bird darts in front of you and you think "hey, was that a Bell's Vireo?"  You need to figure out how many alternatives it could be and you come up with Warbling Vireo, Ruby-crowned Kinglet, or Philadelphia Vireo. This means your guess is 1 out of 4 or 0.25.  That also means everything else is 3 out of 4 or 0.75. Let's call our bird the possibility or P and let's call the other birds the other possibilities or OP.  This works when we are equally sure or unsure of the identity. Read example 3 if this isn't the case. 

2. The proportion of sightings that bird would make up or the relative population

  • Sounds complicated and sometimes it is. If you're lucky, some expert will tell you something like 1 of a 1000 sightings is that bird.  Such as 1 of a 100 horned larks is a Lapland Longspur (my guess). You just need to convert that number to a decimal so 1 out of a 100 becomes 0.01 and 1 out of a 1000 is 0.001 and so on. Let's call this number our chances or C. That means the chances of being something else is 1-C and we can call that number other chances or OC. So if you're bird is 1 out of 100 then C = 0.01 and OC = 0.99
  • If you want to be fancy then get a population estimate. You can find them for the breeding season here, and winter populations here. Winter populations are based on the Christmas Bird Count and are given as in index. That's fine - actually easier that way. If you have populations then look at the relative size of the populations. If you add the populations of the vireos and kinglet all together and Bell's Vireo is 1/10 the population of all those added together then C =0.1. If you're using an index like breeding bird survey or Christmas bird count data then add the indices together and divide this into your target bird. This should give you a number less than 1 (it better). 
Now you're just multiplying, adding, and dividing - in that order. Do the things in parenthesis first. That's it. 

Here's the formula:
(P x C)/((P x C) + (OP x OC))

Boom. Done! 

Example 1: 4 birds and not a clue

Let's use the vireo example. What is the probability of my bird being a Bell's Vireo coming through my area?

P = 0.25, C=0.00001 (that's 1 in 100,000 - probably an overestimate) 
OP = 0.75 and OC = 0.99999

This give me the probability of my bird being a Bell's Vireo = 0.00000003.  

So even though it could have been one of four birds, probably not a Bell's Vireo.

Example 2: 2 birds and not a clue

Better binoculars!  OK this bird is definitely not a kinglet or Philly vireo. This changes everything because the population I'm comparing Bell's to is much smaller than all the other birds added together. Now it's just kinglets. There's lots of them but not as many with the other vireos removed. So

P = 0.5, C = 0.0001
OP = 0.4, OC = 0.9999

This gives me the probability of the bird being a Bell's Vireo of 0.0001. Which is the relative proportion of birds out there. When there's only two birds, the probability is the relative size of the population.

Example 3: 2 rare bird and you're very sure (but not completely)

Better binoculars and more confidence but Bell's are still rare in the area. Yay. Now you're 98% sure that's what it was. But what's the actual probability that you're right? Now we can alter P to reflect our beliefs. 

P = 0.98, C = 0.0001
OP = 0.02, OC = 0.9999

This gives me a probability of 0.005 (1 out of 200) of the bird being a Bell's Vireo even though I was 98% sure. The problem is Bell's just aren't that common. 

Example 3: uncommon (not rare) bird and you're very sure (but not completely)

Better binoculars, more confidence and you go where Bell's are breeding though still less than kinglets. 

P = 0.98, C = 0.2
OP = 0.02, OC =0.8

This gives me 0.92. So a 92% chance that the bird is a Bell's Vireo.

Example 4: Rare bird but super confident!

You are the expert of Bell's Vireo's and you see one out of the range. What now? You are 99.999% confident! Like example 1 but after years of experience. 

P=0.99999, C= 0.00001
OP = 0.00001 OC=0.99999

There's only a 50% chance that you did see a Bell's Vireo. 

Crap. 

Example 5: Rare bird but you know you got it right

This means you identified it correctly and you're positive.

P=1, C= 0.00001
OP =0, OC=0.99999

This gives me a p = 1. Which is certainty. What did you think the probably was going to be?

What does this all mean? If you're not 100% positive, you're probably wrong when it comes to very rare birds. The rarer the bird is, the more likely it is that you're wrong even when you are very very obnoxiously confident.  

Happy Birding!

No comments:

Post a Comment