Cleaning up and commenting changes to npglpreg