How can I access the row index numbers on a data frame in R?

Posted by user123276 on Stack Overflow See other posts from Stack Overflow or by user123276
Published on 2014-06-05T15:21:19Z Indexed on 2014/06/05 15:24 UTC
Read the original article Hit count: 105

Filed under:

I have a data frame that was sampled from another data frame. As a result, when I print the output of the data frame, I get a jumble of numbers on the left hand side of the data frame. The original data frame was nicely numbered from 1,2,3,4,5, and so on. But my new data frame is numbered 5,15,3,65, etc on the left hand side. Is there a way I can access the row index information for a data frame in R? thank you!

© Stack Overflow or respective owner

Related posts about r