The transcendentalist movement, made famous by writers such as Ralph Waldo Emerson and Henry David Thoreau originated from the ideas of the importance of nature and the natural world and man's inner spirituality, which could be transformed by interacting with nature. Thoreau, particularly, spent a long time living very close to nature, and he wrote about it in Walden.
Melville, on the other hand, could be said to be an anti-transcendentalist, especially in Moby Dick, because he depicts nature not as uplifting and benevolent but as cruel and frightening. The whale itself is the main representation of the dark side of the natural world, preternaturally aware, with a grudge against humans. The sea is also portrayed as dark, dangerous and unforgiving. Melville was definitely not portraying nature in any kind of romantic way. He was a realist, from his intricate and lengthy descriptions of the whale's whiteness, to the cruel death of Captain Ahab.