flashing the red flag vs have the rag on

flashing the red flag

have the rag on

How often have the words flashing the red flag and have the rag on occurred in a corpus of books? (source: Google Ngram Viewer )