I want to run a Monte Carlo uncertainty analysis in a program I am creating. I've got the framework for my Monte Carlo analysis set up and it runs fine except for one thing: my method of variation.
My method of random variation so far is to create a Normal Raster (sa.CreateNormalRaster) with the cellsize and extent of my existing DEM, adjust the Normal Raster values so they fall within the RMSE of my DEM (+/- 0.5 ft), and then add that adjusted Normal Raster to my existing DEM. My DEM has a 5.0 ft resolution and adjacent cells vary by less than 0.2 ft, usually; the terrain is very flat. The potential for adjacent cells to vary by up to 1 ft is unacceptable for my purposes.
I need to somehow spatially correlate these random values so I can apply them to my DEM in a way that makes sense. I know this is a somewhat tall order given the complexity of the published literature on this topic. I don't necessarily need to correlate the random values with the spatial covariance of the DEM at this point in time (although that would be preferred). It's my understanding that I will very likely need to bring in another program (like R) to do the latter. For now, I would ideally like to do something within Python.