I would like to compare vector vs raster data. So i try to fix a problem using both ways.
I made it in vector first :
coastline<-readShapeSpatial("shp") wets<-readShapeSpatial("shp") wetb<-gBuffer(wets,width=500,byid=T) #doing a buffer of 500m of the wetlands wetb2<-gBuffer(wets,width=1000,byid=T) #doing abuffer of 1000 wetb1$vat=0 # assigning a new column of 0 in the buffer i created wetb2$vat=5 # assigning a new column of 5 in the second buffer coastline$vat=10 #assigning a new column of 10 in the rest of the land
Now how would i write the same thing in raster?
My thoughts are that i should turn the coastline and the wetlands into raster first off.How would i do that and what after that?