To grab someone around the neck with your arm, pull their head against your body (thus subduing them), make your other hand into a fist, and grate your knuckles painfully against their scalp. If you're sneaky enough, grabbing them around the neck may not be necessary.
A favorite tactic among bullies and older siblings.
Hey! Don't give me a noogy! It breaks my hair! - My sister
The idea that a noogy is rubbing someone on the head is incorrect that is a dutch rub. Anyone who has ever watched Classic Saturday night live knows that a noogy is given by making a fist and extending the knuckle of the middle finger so it sticks out a bit then rapping someone on top of the head with it. This from the classic bits where Bill Murray and Gilda Radner played nerdy schoolkids.
Dude1: What's the matter?
Dude2: that ass Bobby just got a running jump and gave me a flying atomic noogy. I think I might have a concussion.