[R] Error in rownames

Chris Jackson-Jordan jacksonjordancm at gmail.com
Fri Sep 19 16:10:20 CEST 2014


Dear fellow R users,

I am trying to run the random forest and Yaimpute packages in R to
impute a grid to project in a gis. However, after running the
imputation I keep getting an error in the rownames. This sounds simple
enough, but I cannot figure out what these rownames are reffering to.
Any ideas? I am fairly new to R so im sure it is an easy fix. Any help
would be awesome.

Thanks,

Chris


> training <- read.csv("D:/R_Desktop_Data/RF_RespSurf/RndmPts_RespSurfMIII.csv")> y <- subset(training, select = c(ResponseSu))> x <- subset(training, select = c(sinaspect, habitat, slope, elevation, cosaspect, disttoroad, disttowat))> type.rf <- yai(x=x, y=y, method="randomForest", rfMode="regression", ntree= 2000)> outfile <- list(Type = "D:/R_Desktop_Data/RF_RespSurf/RespSurf_Reg.asc")> xfile <-list(sinaspect ="C:/Users/jacksonjordancm/Desktop/R_Desktop_Data/RF_NNimp/ModelI/ASCII_Files2/sinaspect.asc", habitat ="C:/Users/jacksonjordancm/Desktop/R_Desktop_Data/RF_NNimp/ModelI/ASCII_Files2/habitat.asc", elevation ="C:/Users/jacksonjordancm/Desktop/R_Desktop_Data/RF_NNimp/ModelI/ASCII_Files2/elevation.asc", disttowat ="C:/Users/jacksonjordancm/Desktop/R_Desktop_Data/RF_NNimp/ModelI/ASCII_Files2/disttowat.asc", disttoroad ="C:/Users/jacksonjordancm/Desktop/R_Desktop_Data/RF_NNimp/ModelI/ASCII_Files2/disttoroad.asc", slope ="C:/Users/jacksonjordancm/Desktop/R_Desktop_Data/RF_NNimp/ModelI/ASCII_Files2/slope.asc", cosaspect ="C:/Users/jacksonjordancm/Desktop/R_Desktop_Data/RF_NNimp/ModelI/ASCII_Files2/cosaspect.asc")> AsciiGridImpute(type.rf, xfile, outfile)Rows per dot:  19  Rows to do: 1900
ToDo: ....................................................................................................
Done: .Error in `rownames<-`(`*tmp*`, value = c("23x0049", "23x0050",
"23x0051",  :
  attempt to set rownames on object with no dimensions

	[[alternative HTML version deleted]]



More information about the R-help mailing list