by a hair vs painstakingly

by a hair

painstakingly

adv
  • In a painstaking manner; very slowly and carefully. 

How often have the words by a hair and painstakingly occurred in a corpus of books? (source: Google Ngram Viewer )