Statistical Experimental Design in Compressed Sensing Set-ups for Optical and Transmission Electron Microscopy