i have data frame like this :
1 2 3 4 5
1 0.1 0.2 0.5 0.4 0.8
2 0.6 0.8 0.4 0.7 0.2
3 0.6 0.1 1.8 0.7 0.2
4 0.6 0.7 0.4 0.6 0.1
Now , i want to search for the number 0.8 only in first two rows in column no. 5 and 0.2 in rows 3 and 4 in tha same column.
and i have 2000 rows and ofcourse can not do it manually.
Is there a way to do it in R?
Your question is very unclear.
If you want the position of the
.8, this will do:If you want those with two
.2just below, in the same column,you can use: