fixed gendata, added some sample documentation