World War I broke out during a time when American music was already at something of a crossroads. Ragtime, which had dominated American popular music for the past few decades, was being challenged by jazz. As a result, the music of this wartime era was diverse. Both of these genres are reflected in the war music, making it a useful tool for studying the state of American music around 1918.
"How Ya Gonna Keep 'Em Down on the Farm" is representative of the sort of jazz that was finding a large audience during these years. It's fairly conventional, and there is an easily identified beat. In fact, there's more than a hint of Dixieland jazz in the song. Dixieland was among the earliest expressions of jazz. And since Dixieland, like ragtime, incorporated many march-like rhythms, it also provided something of a segue from ragtime to jazz.
Other World War I songs were more thoroughly ragtime. The best example is "When Alexander Takes His Ragtime Band to France." Written in 1918, the song took the syncopated, ragged march rhythm of ragtime and set it to a story about American soldiers heading off to war.
As an interesting musical contrast, check out this 2007 cover of "How Ya Gonna Keep 'Em Down on the Farm" by acclaimed indie musician Andrew Bird. He uses the same lyrics, but he completely changes the feel of the song by making the music much slower, more contemplative, and more melancholy.
What do you think Bird is trying to convey in his cover? Does it make you think about the song differently?