I repartitioned my harddrive while installing Windows 8 and lost my OS X installation, can I get it back? I tried to install Windows 8 on my MacBook using Boot Camp. Because the normal installer did not recognize the partition that was made by Boot Camp, I opened up the command promt and ran DISKPART. I selected my drive, selected my partition and entered CLEAN – and boom, my entire hard drive shows up as being totally empty. I do have a 1 week old backup and rolling back to it would not be too terrible, but I wonder: is there a way to restore my files?
Repartitioning a disk like that is, unfortunately, a fatal operation for the data on it. There's an outside chance you may be able to take advantage of a data recovery service to extract some of the data from the drive but this is an expensive way to go.

Good thing you have that backup.

As a general rule, before I do anything on my machines at the OS level (upgrade, reinstall, cross-grade, etc.) I take a snapshot of my drive using Carbon Copy Cloner and I test to make sure I can boot the Mac from that copied drive. Once I've confirmed the clone is stable, I proceed with the work on the main drive. If I goes wrong, I just clone the external drive back to my main drive and it's like I never messed it up in the first place.