Find row numbers for adjacent entries
adjacent_rownums.RdGiven .DF, find the row numbers that contain the first instance
in col_name of adjacent entries,
this function finds the row number of the adjacent entries.
Arguments
- .DF
the data frame in which to search for
entriesincol_name.- col_name
the column of
.DFin which to search for consecutiveentries.- entries
a vector of length 2 representing the consecutive entries in
col_namefor which to search.
Value
an integer vector of length 2 giving the rows for entries[[1]] and entries[[2]], whose difference is 1.
NULL if no consecutive entries are found in col_name.