How do I introduce row names to a function in R
- by Tahnoon Pasha
Hi I have a utility function I've put together to insert rows into a dataframe below. If I was writing out the formula by hand I would put something like
newframe=rbind(oldframe[1:rownum,],row_to_insert=row_to_insert,oldframe[(rownum+1:nrow(oldframe),] to name row_to_insert. Could someone tell me how to do this in a function?
Thanks
…