Monthly Archives: July 2013

Bayes Watch

I hope the title hasn’t misled you. I’m afraid this post is about probability, not Pamela Anderson.

It won’t be too technical, and will draw on a really important real-life application. Take the example of routine screening for breast cancer, where all women of a certain age are given a mammography to test for the disease. Imagine you were given the following information:

The probability that one of these women has breast cancer is 0.8%. If a woman has breast cancer, the probability is 90% that she will have a positive mammogram. If a woman does not have breast cancer, the probability is 7% that she will still have a positive mammogram. Imagine a woman who has a positive mammogram. What is the probability that she actually has cancer?

Don’t worry if this leaves you hopelessly confused – so was I when I first encountered this problem. I guessed an answer of around 90% – after all it says if you have cancer there is a 90% chance you’ll get a positive mammogram. But that’s the probability of you having a positive test given that you have cancer. The question asks, what is the probability of you having cancer given that you have a positive test. It turns out there’s a huge difference between the two.

The difference is that sometimes you can have cancer and still get a negative test (this is a false negative). If 90% of those with cancer get a positive test, that still leaves 10% of those with cancer getting (wrongly) the all clear. You can also not have cancer and still get a positive test (this is a false positive). As it says, 7% of those without cancer will be told they have it. No test is a 100% accurate; human error can creep in and samples get mixed up, the technology malfunctions etc.

One way of making the problem a little easier to solve is to eschew the probabilities and %’s, which people find hard to understand, and just count the number of times things happen. If we translate our above problem as follows using frequencies:

8 out of every 1,000 women have breast cancer. Of these 8 women with breast cancer, 7 will have a positive mammogram. Of the remaining 992 women who don’t have breast cancer, some 70 will still have a positive mammogram. Imagine a sample of women who have positive mammograms in screening. How many of these women actually have breast cancer?

This is exactly as before. But we say 8 out of 1,000 rather than 0.8%, even though they mean the same thing. Reading this, it becomes easier to solve the problem. Counting those who get a positive mammogram, we see there are 7 + 70 = 77. But only 7 of these have cancer. So the chances of you having cancer if you get a positive mammogram is 7/77 or about 9%.

This is quite small. Why? Well, even though 90% of those with cancer got a positive test, there was only a small number with cancer to begin with (8 in fact). A large percentage of a small number still gives you a small number. Meanwhile only 7% of those without cancer got a positive test. But there were a large number of women without cancer (992). A small percentage of a large number gives you a large number. It was this large number that swamped the small number – the number of false positives outnumbered the true positives, and so only a small proportion of those with positive tests actually have the disease.

So this is immensely important. If ever you get a positive test for a disease, remember it doesn’t necessarily follow you have the disease. Depending on the number of false negatives and positives, you might have a very small chance of actually having the disease you’ve tested positive for. Many people’s world’s have fallen apart because they have been told they test positive for a disease, be it breast cancer or HIV. But they, or their doctors, never stop to think that many people can still get a positive test even though they don’t have the disease. In our example above, most of the women with positive tests didn’t have the disease (70 without cancer versus 7 with). If this was explained to them, they could realise that a positive test is not conclusive. They could find out a bit about the probabilities that you actually have the disease or that the test has misled you in this case, and maybe ask for more tests.

Either way, you know that a positive test shows you have the chance of having the disease, it’s not a death sentence. You’d feel a lot better knowing that a positive mammogram meant there was a 9% chance of having breast cancer, not a 90% one.

Unfortunately, research has been taken on how many doctors understand all this reasoning, and scandalously few do. They studied medicine, not statistics after all. If ever you get a positive test, press your doctor on these points to ensure you are getting the right information.

A picture tells a thousand words: Sometimes pictures help work these problems out. One can draw a tree diagram:

Bayes tree diagram for cancer screening

This shows more clearly the 77 with positive tests, of whom only 7 have cancer.

You can also ‘think inside the box’:

bayes box for cancer screening

A little bit more: I realise I haven’t yet explained the title. The type of probabilistic thinking used in this post is called Bayesian probability, named after Thomas Bayes, a Presbyterian minister who did work in mathematics. I won’t go into too much detail (I don’t understand a lot about it myself), but it gives a way of telling us how we should update our beliefs given the evidence we find.

In the above breast cancer screening example, we wanted to find how much the evidence (the mammography test) should lead us to believe we had cancer. It can be applied to any of our beliefs and the evidence we hold for them.

The example I’ve used comes from an excellent book, Gerd Gigerenzer‘s Reckoning with Risk:

Reckoning with Risk book cover

Leave a comment

Filed under Uncategorized

From Here to Eternity

A post-church pub discussion led to me and a friend speculating about Heaven.

Heaven

It’s a subject that lends itself to speculation, as there is no hard-and-fast evidence that anyone can show you about what Heaven is like, or that it exists. Christians believe that its existence and certain other of its characteristics have been revealed to us from God, and we take these on faith. But there’s still an awful lot left hanging about what it’s like.

Some of the missing details I wondered about:

  • What’s the state of technology in Heaven? It says in the Bible that there are roads and gates, and other made things. Will there be televisions or kettles, sheds or computers? Will we have cars or planes to get about in – or will we be able to fly or teleport unaided?
  • Will all the works of art made over human history – be they books, or paintings, or films – be available to us in Heaven? Will we be able to get around to reading all the books we wished we’d read, or watch those TV shows that always clashed with other things? My friend thought not, as all human art will contain sinful things like death, hate and lust that will have no part in the new creation. I thought this was a shame, as often great art deals with nasty things.
  • Will we know everything in Heaven? It sounds nice if we did, but then we’d lose the thrill of discovery and scientific advancement and the hard but rewarding slog of reducing the extent of our ignorance.

You might think these are all trivial thoughts around such a big subject (- I suspect many more of you will think I’m deluding myself that such a place exists), for there are far more important questions, and there will be far greater things to concern ourselves with there, but these seem important to me. Anyway, I’m sure I’ll know one way or the other one day.

Leave a comment

Filed under Uncategorized

Economics, Part 1, Chapter 3

Here is the next instalment from the ‘Economics textbook. It covers the concepts of supply and demand – concepts which are very simple, yet help us understand a lot about how economies function.

If you read it, you should understand why strict anti-drugs laws make drug-dealing so lucrative, and why you would have got a nice pay rise if you survived the Black Death!

.

As this is the last Chapter in Part 1, I’m going to take a break before starting on Part 2. That’s not to say I might not expand upon this Chapter in following posts.

1 Comment

Filed under Uncategorized

The A – Z of Music: E

With famous birthdays all over the news this week, I thought I’d look to see what song was No. 1 when I was born. It turns out it was Madonna‘s Into The Groove – well, not my favourite song. But the previous No. 1 was There Must Be an Angel (Playing with My Heart) by Eurythmics. It’s got an angelic-looking Annie Lennox, a falsetto-ing fatty, and Stevie Wonder doing a harmonica solo. What more could you want from a music video*?

Continue reading

Leave a comment

Filed under Uncategorized

A Name Fit For A King

What’s in a name? That which we call a rose by any other name would smell as  sweet

Romeo and Juliet

With the royal baby born, the next thing everyone wants to know is what name will it be given. I can predict this no better than anyone else, and have no strong opinions on what I’d like it to be called – although I’m sure such excellent suggestions as King Ralph, King Kong, and King S’of’Leon will be ignored.

We’re on much stronger ground when it comes to what past Kings and Queens are called, and in case you’re a little rusty on this:

P.S. The clip is from CBBC‘s fantabulous Horrible Histories television show – which were taken from a series of books of the same name by Terry Deary. I have a nearly-full collection of these books that I started getting when I was 11. They’re an excellent, and fun, way of getting children to learn about history.

Leave a comment

Filed under Uncategorized

Royal Baby Born!

BREAKING!: Will & Kate have had a baby boy. Live scenes from outside St. Mary’s Hospital:

Irreverence aside, I wish the baby boy well. It will share a birthday with my little sister, who became 10 today. If he turns out half as well as she has, we’ll have done well.

1 Comment

Filed under Uncategorized

Jesus Walks, Jesus Walks With Me

A miracle happened last night.

I was out with the Plymouth Street Pastors. As usual, before we went out on our first shift, we had a group prayer. We were told that as we were out on the streets, Jesus would be there with us.

Now, within 10 minutes of starting out, I kid you not, we were passed by a young man with long hair, a beard, white robes and a crown of thorns! I’ll grant you, the tin of Fosters in one hand was a little incongruous, as was the plastic bag of shopping in the other. His clothes had a vague hint of cheap fancy dress shop origins. But still, I’ll take my miracles where I find them.

For those that don’t know, Street Pastors are a group of volunteers from different churches who gather together on a Saturday night and patrol the main nightlife areas. As anyone who’s visited a typical British town late on weekends, there’s plenty to keep an eye on. The drink flows pretty freely, so there’s plenty of opportunity for people feeling sick, having fights, getting teary and emotional and arguing with partners, and unfortunately even deaths and sexual assaults.

An artists impression of Plymouth's nightlife on a Saturday night*

An artists impression of Plymouth’s nightlife on a Saturday night*

When we’re out, we can do a lot of good. We carry with us a big bag where we keep first aid kits, a dustpan and brush to sweep up broken beer bottles, drinks of water for the worse-for-wear, and (what we’re best known for) flip-flops for those slightly inebriated, stumbling young ladies in high heels.

We can also be a great preventative measure. If you see a group of people in uniform nearby, you might think twice about throwing that punch, or following that young lady down the dark alley.

We’ve also saved several lives. A couple of people have been resuscitated by Street Pastors. Our medical help (or at least our calling of ambulances) has prevented deaths. Several suicides have been prevented by our interventions.

But many hundreds of people have benefited us in smaller but no less important ways. We’ve been the shoulder to cry on, or the person to help you into a taxi, or to wait with you until your friends can find you.

We’re really appreciated by the people out of the town, which makes walking the streets until 4am seem worthwhile!

P.S. The title of the post is, following this blog’s tradition of never-knowingly up-to-date cultural references, from a Kanye West song.

Continue reading

Leave a comment

Filed under Uncategorized