Epigraphs are like little appetizers to the great entrée of a story. They illuminate important aspects of the story, and they get us headed in the right direction.
I do not propose to write an ode to dejection, but to brag as lustily as chanticleer in the morning, standing on his roost, if only to wake my neighbors up.
Thoreau's epigraph may be referring to Samuel Taylor Coleridge's famous 1802 poem inspiringly titled "Dejection: An Ode." In this poem, Coleridge, a Romantic poet, relates how a stormy night inspires dark thoughts and "dull pain," keeping the poet from a restful sleep.
Thoreau's epigraph suggests that he feels pretty much the opposite way. He doesn't find nature to be a source of dark thoughts, nor is he depressed or down on himself. He's prepared to crow like a rooster, and he doesn't care if he ruffles a few feathers in the process. To top it off, he certainly isn't interested in sleeping (and we shouldn't be either). Thoreau returns throughout the book to this idea of waking up his readers (Where I Lived.7, 15; Conclusion.20). It's clearly an important motif, so we're not surprised that he brings it up right from the epigraph.