Welcome to today's discussion of literary naturalism. It is not necessary to be a complete nihilist, but it helps.
Naturalism is literary realism that read Darwin, gasped, and said, "Dang, Emerson was wrong! Humans are not the center of the universe, and nature doesn't look out for them. They're just as pointless as the flies we swat every summer afternoon."
This theory was further refined to maintain that humans were the helpless victims of their genetics and their environment, and those two things would conspire to make them miserable at every turn. Further, if they somehow escaped with good genes and good luck, nature itself would try to kill them. The mantra of literary naturalism is "Life sucks, and then you die."
One might wonder why, if writers truly believed that humanity had no point, they bothered to write about it. Possibly they felt that shared misery was more bearable than the lonely belief in their futility. Possibly they just wanted to shock people. More likely, though, and I'm actually being serious here, they got sick of the moral complacency that arose out of Transcendentalism. "If we're so great," a naturalist would ask, "Why was the war so brutal, and why do we continue to exploit everything and everyone we come across?"
Late 19th century American industrialism and expansion came at a price, and often it was a very high one in terms of human life and human quality of life. Children died in industrial accidents; Native Americans died in settlement disputes, and over all of this was the specter of the Civil War, that left many people desperately poor and still oppressed. The naturalists looked at this world and felt confident in saying that people are not inherently good, and life is not full of promise.
Prominent "naturalistic" writers include Ambrose Bierce, Stephen Crane, Theodore Dreiser, Jack London, and Frank Norris. In all their work, we can discern the grey thread of hopelessness, mingled with the red one of vicious nature, looking for its next meal.
It is interesting to note that, with the possible exceptions of London and Drieser, a lot of naturalists died young. Ambrose Bierce was getting up there in age when he disappeared in the Mexican desert but we can assume he wasn't happy about it.