Bandanas apparently are of limited effectiveness. (Although they're definitely better than anything!). I saw a chart the other day that showed the relative effectiveness of various home materials and bandannas and scarves were at the bottom of the list. Here's a peer-reviewed article about the various effectivenesses of materials:
Testing the Efficacy of Homemade Masks: Would They Protect in an Influenza Pandemic?
www.ncbi.nlm.nih.gov
That's a lot of words there. But I am guessing that when they tested the effectiveness of the 100% cotton t-shirts they cut out a piece of the t-shirt and used a single layer of fabric to conduct their test. My bandana is folded over in such a way that I am breathing through at least 3 layers of fabric. I'm going to guess, athough I have not commissioned any tests to prove it, that my 3 layers of bandana will work just as well as a surgical mask.