added new regression based sacmod script, along with some minor changes