Sore head

I had a sore head for about 5 days (21-25 April).  My scalp was sore across the top of my head and covering an area about the size of my hand.  Whenever I moved my hair by running my hand through it I had a sharp pain in the hair folicles.  It also made sleeping rather painful too due to the constant rubbing of the pillow on my hair.  Now the hair is gone I am pain free and can sleep.  This has the doctors a bit baffled as to what was causing it.