I am working with the
predict packages in R for land classification. For each 4-band CIR image, I have created training data in a GIS, run the training data through a model to produce a .csv, which is then input into R's
randomForest algorithm. I am finding the Random Forest supervised classification is seriously overclassifying areas. In fact, I am producing better results using the unsupervised ISODATA algorithm.
Is there a way to implement unsupervised classification with the randomForest package in R? I have attached a section of code I've been using to run supervised random forest classification.
myrf = randomForest(factor(category) ~ band1 + band2 + band3 + band4, data = intable, ntree=2000, importance = TRUE) predict(rasters, myrf, filename="RFtest7.img", type="response", index=1, na.rm=TRUE, progress="window", overwrite=TRUE)