Modifications to SPHOT script (for testing)