Message-ID: <CAJ5oOKVMJq-EwcS2kA8k0Z2v3oJ1PL-fdk_Ypf_tVmVm5KNCsQ@mail.gmail.com>
Date: 2021-02-28T02:13:12Z
From: Bijesh Mishra
Subject: Help post
I have pathogen (1/0) as a dependent variable and total (count) as
independent variable. I have to get 1) KNN on total and 2) get the training
error and training TPR and FPR for k = 5 nearest neighbors using total as a
predictor. and 3) get a plot of training error vs. k for k = 1, 2, ..., 10
with k on the x-axis.
I am not sure how to do this in R. Also, how to know which value(s) of K
would be the most biased in the training error estimate?
Help would be appreciated.
Thanks
Bijesh Mishra.
[[alternative HTML version deleted]]