How do you get rid of stress-related flatulence?

If stress is the . Cause then i guess one option would be to reduce your stress. Ways to address stress. Talk about feelings ; address problems. Don't avoid them. Aim for 7.5 - 8 hours of sleep/ night. Daily physical activity is optimal in a green space. Eat healthfully. Cut out junk carbs, caffeine ; alcohol (or moderate). Try qi gong, tai chi, acupuncture, acupressure, homeopathy, meditation, yoga, exercise >.
Don't swallow air. Lots of causes for flatulence. Stress related? Don't chew gum, worse with sugarless (has sorbitol causes gas, etc), decrease carbonated beverages, coffee (even decaff), don't eat rapidly, drink from straws. Check your diet; some people eat differently when stressed. Watch chocolate intake, fatty foods, alcohol. If this doesn't help, discuss with your doc.