removed unnecessary data.frame usage