Comparing what combat soldiers go through to what a gymnast goes through is ridiculous.
A combat soldier doesn't get a choice. Act or die or others may die.
All gymnasts (all athletes) have a choice to either attempt or not attempt physical feats that require complete mind/body coordination or face failure, and possible life altering injury. If the brain isn't in command of the body today, don't attempt it. From what I've read and listening to her speak, she felt the brain wasn't controlling the body, and, not only might she injure herself, she might do so poorly as to bring the team down. Seems pretty selfless to step aside for the sake of the team and others in the individual events. If she'd have stayed in, the U.S. team and individuals had a good chance of winning nothing. Instead, she bowed out, several others got the chance to compete, and stepped up to the task. The team won a medal, and several individuals medalled as well.
So tell me again why she did the wrong thing?