`geom_smooth()` using formula 'y ~ x' Error: Continuous value supplied to discrete scale

You should make QNR2 like this

QNR2 <- QNR[1:20, c("N2Age", "N3Sex", "sources_Metric", "hygieneSanitation_Metric", "attitudeWASH_Metric")]

then run

dput(QNR2)

and paste the output into a message here.