I have just returned from a 4 night stay in Marrakech. I think this was an ideal length of time as I was able to spend a day in and around the Souks / night market, a day of pampering - Hammam / massage etc, and a day trip to Ourika Valley/Berber Village/Atlas Mountains. I would highly recommend a day trip outside of Marrakech as you get to see a real contrast. I also stayed in the New Town outside of the Medina, I was glad to do this as you could get away from the hustle and bustle if you felt like it.
If you do decide to go and to do a day trip then I highly recommend a guide called Adil. His email address is - email@example.com.
Being a female traveller I was anxious about being hassled etc but I did not come across any of this. Everybody is so friendly and if you have half an ounce of common sense then you will be just fine.