The question is about data frames in R. I want to extract a row from a data frame along with its position (line number) in the original data frame. The idea is to create a new data frame that includes the row information extracted from the previous data frame, as well as the position of the row from the previous data frame.
patchLocalNo <- patchList[which(patchListTop5$sensitivity == patchLocalSpec),]
what I want to do is take the line numbers from patchList that satisfy the condition and add them to the column in patchLocalNo.
Thanks in advance, I searched the Internet and asked employees, and all I can think of is data preprocessing in perl.
source share