Bunch of bug fixes and first try at actually simulating data
Added the makeunique function back in
merged changes from Alex
delete small lines