I'm not sure how to determine the best input values for a search radius to create a TPI for the purpose of predictive soil mapping.

Would this depend on the spatial extent of the area I wish to map?


There really is no expected for this unitless metric. The TPI is the delta of the focal pixel from the mean of the focal window. Obviously, the metric is sensitive to outliers and the larger the focal window the more likely an outlier effect. The best way to incorporate it into an analysis is to develop explicit hypothesis around the effect of a given scale and, perhaps, even test a range of scales. The extent of your analysis would not provide any type of empirical definition of this metrics scale parameter. You could have a small area that is locally hyper-variable or a large homogeneous area.

The R spatialEco package provides a function "hsp" for deriving the Hierarchical Slope Position (Murphy et al., 2010). The HSP is a scale decomposition, across a range of defined scales, providing an integrated scale version of the TPI metric.


Murphy M.A., J.S. Evans, and A.S. Storfer (2010) Quantify Bufo boreas connectivity in Yellowstone National Park with landscape genetics. Ecology 91:252-261

  • I am using a 30 x 30 m DEM and mapping an area approximately 58,611,431 square meters. Would you have any suggestions on a good neighbourhood search radius to use for that? I try putting different values (min/max = 0;100, 0;200, 0;300, 100;200, etc. etc.) and get good looking results but different index value ranges and I need to rescale the values to a suitable scale range. I could potentially use the results I have, but the problem is that I don't know how to justify my input choices. – ATomz Apr 24 '17 at 20:07

I would think that there are a number of factors to consider:

  • Point Data Density
  • Size of area to be mapped
  • Intervening feature size to be ignored
  • Available computing power vs available time
  • Degree of required accuracy

It is often worth using rough cuts the value(s) you are considering with sub-sets of the data to do trial runs or if there is sufficient computing power &/time available doing multiple runs with different parameter values.

  • I am using a 30 x 30 m DEM and mapping an area approximately 58,611,431 square meters. Can you elaborate on the "feature size to be ignored"? Computing time/power isn't an issue and I'd like it to be fairly accurate. How would I justify my neighbourhood search radius choice? – ATomz Apr 24 '17 at 19:59
  • @ATomz if you have areas of anomalous data or sudden step changes you will find that varying the TPI will impact their inclusion/exclusion from the process, examples for soil data include roads, waterways, groups of buildings, rocky ridges, etc. Of course you may wish to create one, or more, separate overlays for such features. – Steve Barnes Apr 25 '17 at 5:58
  • Do you mean just manually take those areas into consideration when interpreting results? and using vector data or a classified raster of the area to look at the discrepancies in the TPI result raster? – ATomz Apr 25 '17 at 14:06
  • @ATomz Definitely the latter but if you have overlays that you can turn on or off when examining the results it can help make sense of anomalies. – Steve Barnes Apr 25 '17 at 18:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.