I was in a big earthquake (1989 California Loma Prieta) and all I was thinking was to get out of my house. Usually they say to prop yourself under a doorway as being a strong part of the house, but my cabin was in the hills, half on stilts. I was taking a nap when it hit and ran out, grabbing the dog, to stand on solid ground. My house slid down the hill about four inches, taking down the chimney.
This is a great question, and very hard to answer. I grew up in California, and knew what to do, and had been in many smaller quakes. When the time comes, it can be very difficult to do what is best, when the instinct tells you to run like crazy! I think I probably did the safest thing-- my house did not collapse, but it did slide. Since then I also try to remember to wear clothes when napping.