added standalone fitting script