finished change from list to data frame