Take a story's temperature by studying its tone. Is it hopeful? Cynical? Snarky? Playful?
Dark, Uncertain, Introspective, Tortured
Aside from the oh-so-hilarious gallows humor of the gravediggers and a few other really-not-so-funny moments, Hamlet is a dark play full of uncertainty and suspicion. From the very first line, "Who's there?" (1.1.1), we're dumped into a world of uncertainty, anxiety, and the very real possibility of ghosts.
It's a perfect world for our hero, Mr. Anxious and Introspective himself. When Hamlet delivers all those introspective and tortured soliloquies about mortality, betrayal, and the futility of life, he brings us into his tortured world view—and only lets us out with his death. Nice.