Mechanics of a Quake
A quake is created when two transform boundaries rub against each other and when so much pressure gets built up and suddenly moves.
In California , the is a famous fault called the San Andreas Fault where earthquakes commonly occur, in this effect, there are 15 - 20 quakes per year in Southern California.