number of observations

Hi,

It is really hard to see what is happening in your case as we have no data. As you can see in my mini example I am able to get the right row to show after filtering and can do it with other assignment as well.

library(tidyverse)

df <- data.frame(
  x1 = c(400:500),
  x2 = c(300:400)
)

df_output <- df %>% filter(x1 == 457)

df_output
#>    x1  x2
#> 1 457 357


df$x1 == 457
#>   [1] FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE
#>  [13] FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE
#>  [25] FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE
#>  [37] FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE
#>  [49] FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE  TRUE FALSE FALSE
#>  [61] FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE
#>  [73] FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE
#>  [85] FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE
#>  [97] FALSE FALSE FALSE FALSE FALSE

Created on 2021-11-03 by the reprex package (v2.0.0)

Chances are your numbers are not truly numeric in your data.frame which will be leading to this problem. Create a reprex and we can help FAQ: How to do a minimal reproducible example ( reprex ) for beginners

2 Likes