changed setdata to set.data