Default Wipe data stay rooted to sell

I want t sell my galaxy nexus rooted unlocked phone. I want to remove all data but keep the phone unlocked and rooted? How do I do that?