[R-sig-Geo] Looping through pixels in a SpatialGridDataFrame

Jan Verbesselt janverbesselt at gmail.com
Thu Dec 22 08:59:07 CET 2011


Hi Jorge,

As for flood modelling; maybe look at the GRASS or QGIS mailing lists. And the following posts:
http://gis.stackexchange.com/questions/5907/flood-modelling-insights
http://www.cs.duke.edu/geo%2a/terraflow/r.terraflow.html
Also;
http://hub.qgis.org/wiki/quantum-gis/Hydrology_&_Hydraulic_modelling

Hope this helps,
Jan


On 21/12/2011, at 1:01 AM, Jorge Cabrera wrote:

> Hello people in the list,
> 
> I am new to R and I am trying to simulate a simple flood model using a digital elevation model and water height data.
> The idea is to find the neighbor pixels of a river and assign to them the values of the DEM, comparing them with the water height data, and were it exceeds the height, this pixel is starting to get flooded, the flood continues to its neighbors taking into account the height from the DEM. These happens until the water height is again below the DEM.
> I need some idea to start, and mainly how to loop inside a SpatialGridDataFrame or SpatialPixelDataFrame and be able to compare between different SpatialGridDataFrames in my case DEM and Water Height.
> 
> I hope the explanation is clear
> 
> Thanks in advance for your help
> 
> Best,
> 
> Jorge
> PD: I am a windows user R version 2.14
> 
> 	[[alternative HTML version deleted]]
> 
> _______________________________________________
> R-sig-Geo mailing list
> R-sig-Geo at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-geo



More information about the R-sig-Geo mailing list