79699311

Date: 2025-07-12 13:36:33
Score: 0.5
Natty:
Report link

Rather than trying to make a pipe work, are you willing to use the with() function?

df <- data.frame(ID=1:6, col1=c(0,1,2,0,5,0), col2=c("A1", "A2", "B1", "B2","C1", "A3"))
with(df, which(col1 == 0 & grepl("A", col2, fixed=TRUE)))
#> [1] 1 6

<sup>Created on 2025-07-12 with [reprex v2.1.1](https://reprex.tidyverse.org)</sup>

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Contains question mark (0.5):
Posted by: FJCC