I read an ADF file in R:
kommuner <- raster( "../../../10-Data/Kommunne_i_Norge_2000/Kommuner2000_100m_100m/100x100_2k/w001001.adf" )
It contains three attributes:
> kommuner
class : RasterLayer
dimensions : 14903, 11906, 177435118 (nrow, ncol, ncell)
resolution : 100, 100 (x, y)
extent : -75900, 1114700, 6449500, 7939800 (xmin, xmax, ymin, ymax)
coord. ref. : +proj=utm +zone=33 +datum=WGS84 +units=m +no_defs +ellps=WGS84 +towgs84=0,0,0
data source : /path_to/w001001.adf
names : w001001
values : 1, 435 (min, max)
attributes :
ID COUNT OBJ
from: 1 63390 0101
to : 435 26048 0903
Now, the question is how I can access the OBJ feature in an easy way. By easy I mean something similar to how I would access a column in a data frame, such as DF$OBJ. Could you help?
Secondly, I would like to create a new attribute that is linked to OBJ. Let's call it NI. How can I create the NI attribute, say, let NI = 4 + OBJ * 5?
Lastly, I would like to run a regression with the NI feature in this kommuner variable, which is the y-variable, against a number of other features in other variables. Could you provide an example so that I can imitate?