Row-wise operations are alway a little tricky in R with atoms being vectors.
How about this combined purrr trick?
library(tidyverse)
df <- tribble(~n, ~s, ~b, 1, 2, NA, NA, 4, NA, NA, 8, 7, 9, NA, 11, NA, NA, NA)
df %>%
mutate(valid_in_row = map(., ~(!is.na(.x))) %>% pmap_int(sum))
# A tibble: 5 x 4
n s b valid_in_row
<dbl> <dbl> <dbl> <int>
1 1 2 NA 2
2 NA 4 NA 1
3 NA 8 7 2
4 9 NA 11 2
5 NA NA NA 0
The intermediate step is:
> map(df, ~(!is.na(.x)))
$n
[1] TRUE FALSE FALSE TRUE FALSE
$s
[1] TRUE TRUE TRUE FALSE FALSE
$b
[1] FALSE FALSE TRUE TRUE FALSE