Humor has historically been tied to the mores of the day. The Yellow Kid was predicated on what people thought was funny about the immigrant Irish. When you're different in a society you're funny.
Humor results when society says you can't scratch certain things in public...
Humor is merely tragedy standing on its head with its pants torn.