I have a data set where my observations are geographically referenced by longitude & latitude, as well as by township & range. If you're unfamiliar with township & range:
The land is divided into survey townships of roughly 36 square miles. This is done by establishment of township and range lines. Township lines run parallel to the baseline, while range lines are true meridians. (https://en.wikipedia.org/wiki/Public_Land_Survey_System)
I want to run two different configurations of a Random Forest model. One where I account for spatial autocorrelation by including longitude & latitude as predictors, and one where I use township & range for the same. The point is to develop two models of different "spatial resolution", where the one with longitude & latitude is the high-precision case and the one with range & township is the lower-precision case (this would in a way resemble a county-level fixed effect).
At the moment, I have both these variables encoded as numeric variables (I am using R). For longitude & latitude, the precision can be infinitely increased by increasing the number of decimals, so this seems reasonable.
However, range & township may only be integers (there's no such thing as township = 5.5
). I have tried to encode them as integers, but this doesn't seem to make any difference, as R seems to treat them in the same manner as normal numeric variables. If I encode them as factors, the variable importance gets way more messy since each category acts as a dummy variable, and I am not sure whether it's "more correct" anyway.
My question is: Would there be any problems related to keeping the township & range variables as numeric in this case? If so, does anyone have any suggestions on how to store these variables in a different way?
PS, I have read this post: GLMM: Elevation as numerical or factor in model?, but since random forests are capable of modelling non-linear relationships, the accepted answer does not seem to be exactly what I'm after.