update of nevins's work from 0.6.0 to 0.8.0