1

I am running Knn algorithm in R studio. The packages that I am using is class:

  • Version is 3.0.2 in Rstudio.
  • Number of Tuples :50000
  • Number of attributes : 8

The dataframe is Final_Data and training and testing data frames are Train1 and Test1.

I am getting the error as:

Error in if (inherits(X[[j]], "data.frame") && ncol(xj) > 1L) X[[j]] <- as.matrix(X[[j]]) : 
  missing value where TRUE/FALSE needed

I have cleared all the missing values .

Pls help me out in resolving this issue .

knn(Train1, Test1, "DepTime", k = 1, l = 0, prob = FALSE, use.all = FALSE).

The above knn function is the code that I am running and DepTime is class label.

Kenry Sanchez
  • 1,703
  • 2
  • 18
  • 24
user3292373
  • 483
  • 3
  • 8
  • 25
  • 2
    You need to make your question [reproducible](http://stackoverflow.com/a/5963610/1412059). At least, provide the full error message. – Roland Feb 10 '14 at 10:15

0 Answers0