Select to view content in your preferred language

Extract By Mask but based on elevation

1869
4
Jump to solution
11-09-2021 01:00 PM
AnnaPearson
Occasional Contributor

Does anyone know if there's a way to do something like Extract by Mask but along the z-axis instead of x/y?

I have many raster grids representing surfaces and I want to extract just the cells that are below a given surface (in other words- essentially 'clipping' them so nothing peeks above the top surface). 

I can adjust to other file types like multipatches if anyone knows of a way to do this with another file type. 

The best I've found so far is trying to do something with Extract By Attributes, but I don't have much of any experience with SQL and I'm not sure if that could work anyway (?), since raster attribute tables are one row per 'Value' instead of one row per cell. 

0 Kudos
1 Solution

Accepted Solutions
AnnaPearson
Occasional Contributor

Ah, the difference is that my top surface is variable, not one constant maximum elevation--- but that helped me realize I can make one raster to consider against a constant value! Thank you!

I just got it to work in Raster Calculator as:

Con((Top Surface -Bottom Surface)>=0 ,Bottom Surface)

View solution in original post

0 Kudos
4 Replies
DanPatterson
MVP Esteemed Contributor

You can create the "mask" by many ways, but

Con (Spatial Analyst)—ArcGIS Pro | Documentation

would seem to fit the bill.

What do you want the values to be above your threshold elevation?  nodata?  your threshold value?

 


... sort of retired...
AnnaPearson
Occasional Contributor

Nodata would be perfect for values that go above the top surface. Thank you, Con looks very useful! I'm still similarly stuck on the clause though, i.e. wanting something like:

Conditional raster: the top surface

True raster: the surface I want to 'clip'

False raster: none, that way it shows nodata if the surface goes above the top surface

Expression: Where Value (top surface) is greater than Value (surface I want to 'clip')

0 Kudos
DanPatterson
MVP Esteemed Contributor

maybe setnull diretly

A # your elevation raster, "10" is the maximum elevation
B = SetNull(A > 10, A)

Setting values to NoData with Set Null—ArcGIS Pro | Documentation


... sort of retired...
0 Kudos
AnnaPearson
Occasional Contributor

Ah, the difference is that my top surface is variable, not one constant maximum elevation--- but that helped me realize I can make one raster to consider against a constant value! Thank you!

I just got it to work in Raster Calculator as:

Con((Top Surface -Bottom Surface)>=0 ,Bottom Surface)

0 Kudos