Edgar is Quagmire's ventriloquist dummy that he uses when he tries to distract himself after losing his penis to a shark in "The Unkindest Cut".
However, during his show at the Quahog Playhouse, it becomes apparent that he intends to use Edgar to goad himself into taking his own life. The guys stop him, although they all have their own dark thoughts as they hold Quagmire's gun.