Tediore weapons/guns are thrown like grenades when their clips are spent. (The gun respawns in your hand during the reload.) How much damage does this do, what is the explosion's blast radius/area, and how is it affected by your character and the gun's stats?
I can't provide exact numbers, but I have noticed that the more ammo left in the clip, the bigger the boom and the higher the damage. So firing once and then throwing your gun will cause quite a bit more damage than throwing an empty gun.
The usefulness of this is balanced by the fact that any ammo in your clip is used up when you throw the weapon. So an almost-full clip will do more damage but it chews through your ammo in no time at all - and of course you have to actually hit your target for it to be of any worth.
Note that you can't throw your 'last' weapon - i.e. if you don't have enough ammo to do a proper reload, your character won't throw the weapon.
Edit - More info based on Ben Brocka's comments: The explosions appear to always be the same size but the damage is affected by the gun's Damage stat. It's a fair assumption that Gun Damage would be the relevant Badass skill, then. Experimental evidence with Badass ranks enabled/disabled would be useful to confirm this.
Additionally, if you throw an elemental weapon, the explosion will do damage of that elemental type (e.g. throwing a Corrosive weapon will produce a Corrosive explosion). Non-elemental weapons and explosive weapons both deal explosive damage.