I am trying to do a kernel logical regression in R. Is there a package that does this?
stats::ksmooth gives you regression of the Nadaraya-Watson core:
stats::ksmooth
with(cars, { plot(speed, dist>40) lines(ksmooth(speed, dist>40, "normal", bandwidth = 2), col = 2) lines(ksmooth(speed, dist>40, "normal", bandwidth = 6), col = 3) })