Restoring to factory defaults is a drastic measure. If you did something that suddenly made your computer begin to perform badly, or even if you didn't, you should try using "System Restore" in the control panel area first.
Read about System Restore. Eat a good meal, block out some time, and plan to sit and work on this for at least an hour. You should have a log book (physical notebook) for every computer you own. Keep a written log of what you do and how things turn out. Best case, it will be fixed in 15 minutes. Your log book will become a good reference tool after the years when similar problems present.
Edit: Back it up! You should ensure that your data files (Microsoft documents, images, iTunes library, etc.), essentially everything in your (and your other users'), MyDocuments folder is backed up to an external hard drive before attempting to fix your computer. In fact, you should periodically back up your files even when things are going smoothly. The $80 you spend on an external hard drive today can save you $800, hours of grief, and irreplaceable files tomorrow.
Also, follow good advice about antivirus and malware removal, as given above.