<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Why is Clip Raster resampling? in ArcGIS Spatial Analyst Questions</title>
    <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/why-is-clip-raster-resampling/m-p/1244146#M11836</link>
    <description>&lt;P&gt;Thanks &amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/215600"&gt;@DanPatterson&lt;/a&gt;&amp;nbsp;.&amp;nbsp; I did not consider the environmental settings.&amp;nbsp; However, those were not the issue.&amp;nbsp; The magnitude of my original issue is more minor than originally perceived – i.e. the raster values are NOT being resampled. &amp;nbsp;But, the mechanism that led to my reaction has added multiple issues when visualizing and mapping raster data that I cannot solve.&amp;nbsp; To simplify my issue, clipping a raster led to a colorbar range being WAY higher than the original.&amp;nbsp; The max value changed from 938 ft to 1885 ft.&amp;nbsp; I assumed that Clip Raster had resampled my data, but that has turned out to be incorrect.&amp;nbsp; Opening the original raster dataset in a Pro map does not display the full pixel value range - in the default “Stretch” Symbology. In my case: 0 to 1885ft.&amp;nbsp; It displays as 0 to 938ft. &amp;nbsp;The default Stretch Type = "Percent Clip” at 0.5 on either end.&amp;nbsp; The ONLY way to automatically display the color bar with the proper range is by switching from Stretch to Classify, in this case with the default Natural Breaks (Jenks). &amp;nbsp;Tinkering with Clip values or Standard Deviation within Stretch change the raster rendering but NOT the colorbar labelling or scale.&amp;nbsp; In regards to the Env. Variables you suggested &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/215600"&gt;@DanPatterson&lt;/a&gt;&amp;nbsp;, only Snap Raster is applicable for the tool.&amp;nbsp; The result is different, but the raster resolutions don’t EXACTLY match the original or the output from tool without Snap Raster.&amp;nbsp; Either using Snap Raster or NO_MAINTAIN_EXTENT did not match cell sizes, albeit very slightly.&amp;nbsp; Out to the 10th decimal.&lt;/P&gt;&lt;P&gt;Yes the cell size change is incredibly minor, but perceivably when toggling the two datasets.&amp;nbsp; The bigger question is why does Stretch NOT use the full range automatically and why doesn't tinkering with parameters in standard deviation or clip stretch type change the range labels?&amp;nbsp; THAT is what I’m interested in now and ultimately what led to my panic.&amp;nbsp; 1) Why is Stretch not changing the range and labels in response to changing parameters and 2) Why is the default symbology clipping my range upon initial loading?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="example_clipped.png" style="width: 591px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/59404i9F0C74C5F92BDD55/image-size/large?v=v2&amp;amp;px=999" role="button" title="example_clipped.png" alt="example_clipped.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Above show how the clipped and original load and the colorbar scale that basically requires manual labelling or switching to a different Stretch type.&lt;/P&gt;</description>
    <pubDate>Wed, 28 Dec 2022 23:17:22 GMT</pubDate>
    <dc:creator>ZacharyUhlmann1</dc:creator>
    <dc:date>2022-12-28T23:17:22Z</dc:date>
    <item>
      <title>Why is Clip Raster resampling?</title>
      <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/why-is-clip-raster-resampling/m-p/1243639#M11834</link>
      <description>&lt;P&gt;Seems clipping a raster to a polygon should be straightforward.&amp;nbsp; I have a raster, I have individual polygon feature layers selected from a feature class.&amp;nbsp; The polygons are rectangles.&amp;nbsp; Same projection.&amp;nbsp; I want to loop through it in Python ultimately, but I have tried both via Python and in the GUI - same result.&amp;nbsp; Note that even using a feature layer with one feature and not setting clipping_geometry to NONE, the results are identical.&amp;nbsp; Here is my code:&lt;/P&gt;&lt;LI-CODE lang="python"&gt;arcpy.Clip_management(r'path/to/raster(an adf)',"", 'ras_name_out', 'feature_lyr_from_TOC', "#","ClippingGeometry","NO_MAINTAIN_EXTENT")&lt;/LI-CODE&gt;&lt;P&gt;The final argument/parameter is optional and the documentation (&lt;A href="https://pro.arcgis.com/en/pro-app/latest/tool-reference/data-management/clip.htm" target="_blank"&gt;https://pro.arcgis.com/en/pro-app/latest/tool-reference/data-management/clip.htm&lt;/A&gt; ) states this:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;SPAN&gt;NO_MAINTAIN_EXTENT&lt;/SPAN&gt;—&lt;SPAN&gt;The cell alignment of the input raster will be maintained and the output extent will be adjusted accordingly.&lt;/SPAN&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;SPAN&gt;Yet my output raster has clearly been resampled.&amp;nbsp; Pixels are slightly shifted, the pixel value range (DEM) changed.&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;FYI - I am trimming excess NaN values from existing raster datasets.&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I don't understand why NO_MANTAIN_EXTENT is resampling.&amp;nbsp; Should be simple.&amp;nbsp; If this data were given to me as non-proprietary data type like a GeoTiff I could have easily batch processed these in GDAL.&amp;nbsp; Should be simple.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Dec 2022 23:29:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-spatial-analyst-questions/why-is-clip-raster-resampling/m-p/1243639#M11834</guid>
      <dc:creator>ZacharyUhlmann1</dc:creator>
      <dc:date>2022-12-23T23:29:52Z</dc:date>
    </item>
    <item>
      <title>Re: Why is Clip Raster resampling?</title>
      <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/why-is-clip-raster-resampling/m-p/1243642#M11835</link>
      <description>&lt;P&gt;snap raster&lt;/P&gt;&lt;P&gt;cell size&lt;/P&gt;&lt;P&gt;extent&lt;/P&gt;&lt;P&gt;These are the three important things that need to be set and considered&lt;/P&gt;&lt;P&gt;&lt;A href="https://pro.arcgis.com/en/pro-app/latest/tool-reference/environment-settings/snap-raster.htm" target="_blank"&gt;Snap Raster (Environment setting)—ArcGIS Pro | Documentation&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://pro.arcgis.com/en/pro-app/latest/tool-reference/environment-settings/cell-alignment.htm" target="_blank"&gt;Cell Alignment (Environment setting)—ArcGIS Pro | Documentation&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://pro.arcgis.com/en/pro-app/latest/tool-reference/environment-settings/cell-size.htm" target="_blank"&gt;Cell Size (Environment setting)—ArcGIS Pro | Documentation&lt;/A&gt;&lt;/P&gt;&lt;P&gt;and if the coordinate systems are not the same&lt;/P&gt;&lt;P&gt;&lt;A href="https://pro.arcgis.com/en/pro-app/latest/tool-reference/environment-settings/cell-size-projection-method.htm" target="_blank"&gt;Cell Size Projection Method (Environment setting)—ArcGIS Pro | Documentation&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 24 Dec 2022 01:49:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-spatial-analyst-questions/why-is-clip-raster-resampling/m-p/1243642#M11835</guid>
      <dc:creator>DanPatterson</dc:creator>
      <dc:date>2022-12-24T01:49:04Z</dc:date>
    </item>
    <item>
      <title>Re: Why is Clip Raster resampling?</title>
      <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/why-is-clip-raster-resampling/m-p/1244146#M11836</link>
      <description>&lt;P&gt;Thanks &amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/215600"&gt;@DanPatterson&lt;/a&gt;&amp;nbsp;.&amp;nbsp; I did not consider the environmental settings.&amp;nbsp; However, those were not the issue.&amp;nbsp; The magnitude of my original issue is more minor than originally perceived – i.e. the raster values are NOT being resampled. &amp;nbsp;But, the mechanism that led to my reaction has added multiple issues when visualizing and mapping raster data that I cannot solve.&amp;nbsp; To simplify my issue, clipping a raster led to a colorbar range being WAY higher than the original.&amp;nbsp; The max value changed from 938 ft to 1885 ft.&amp;nbsp; I assumed that Clip Raster had resampled my data, but that has turned out to be incorrect.&amp;nbsp; Opening the original raster dataset in a Pro map does not display the full pixel value range - in the default “Stretch” Symbology. In my case: 0 to 1885ft.&amp;nbsp; It displays as 0 to 938ft. &amp;nbsp;The default Stretch Type = "Percent Clip” at 0.5 on either end.&amp;nbsp; The ONLY way to automatically display the color bar with the proper range is by switching from Stretch to Classify, in this case with the default Natural Breaks (Jenks). &amp;nbsp;Tinkering with Clip values or Standard Deviation within Stretch change the raster rendering but NOT the colorbar labelling or scale.&amp;nbsp; In regards to the Env. Variables you suggested &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/215600"&gt;@DanPatterson&lt;/a&gt;&amp;nbsp;, only Snap Raster is applicable for the tool.&amp;nbsp; The result is different, but the raster resolutions don’t EXACTLY match the original or the output from tool without Snap Raster.&amp;nbsp; Either using Snap Raster or NO_MAINTAIN_EXTENT did not match cell sizes, albeit very slightly.&amp;nbsp; Out to the 10th decimal.&lt;/P&gt;&lt;P&gt;Yes the cell size change is incredibly minor, but perceivably when toggling the two datasets.&amp;nbsp; The bigger question is why does Stretch NOT use the full range automatically and why doesn't tinkering with parameters in standard deviation or clip stretch type change the range labels?&amp;nbsp; THAT is what I’m interested in now and ultimately what led to my panic.&amp;nbsp; 1) Why is Stretch not changing the range and labels in response to changing parameters and 2) Why is the default symbology clipping my range upon initial loading?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="example_clipped.png" style="width: 591px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/59404i9F0C74C5F92BDD55/image-size/large?v=v2&amp;amp;px=999" role="button" title="example_clipped.png" alt="example_clipped.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Above show how the clipped and original load and the colorbar scale that basically requires manual labelling or switching to a different Stretch type.&lt;/P&gt;</description>
      <pubDate>Wed, 28 Dec 2022 23:17:22 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-spatial-analyst-questions/why-is-clip-raster-resampling/m-p/1244146#M11836</guid>
      <dc:creator>ZacharyUhlmann1</dc:creator>
      <dc:date>2022-12-28T23:17:22Z</dc:date>
    </item>
  </channel>
</rss>

