snap to attention vs take hat off to

snap to attention

take hat off to

How often have the words snap to attention and take hat off to occurred in a corpus of books? (source: Google Ngram Viewer )