<?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 esri.renderers.RasterStretchRenderer - Depreciated - Property: statistics in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/esri-renderers-rasterstretchrenderer-depreciated/m-p/1558135#M86064</link>
    <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[esri.renderers.RasterStretchRenderer]  DEPRECATED - Property: statistics 
️ Replacement: customStatistics 
 Version: 4.31&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;I updated my CDN from 4.27 to 4.31 and now I'm getting this warning. I think it's coming from the imagery2024 constructor. I don't have any statistics set in the code as my layers are in webmaps&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;. I'm unsure how to fix it. &lt;A href="https://codepen.io/underjollyroger/pen/MWMvNpZ" target="_self"&gt;Codepen&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;&amp;lt;link rel="stylesheet" href="https://js.arcgis.com/4.31/esri/themes/light/main.css" /&amp;gt;
&amp;lt;script src="https://js.arcgis.com/4.31/"&amp;gt;&amp;lt;/script&amp;gt;

&amp;lt;script&amp;gt;
    require(["esri/Map",
        "esri/views/MapView",
        "esri/widgets/Search",
        "esri/widgets/Locate",
        "esri/widgets/LayerList",
        "esri/layers/ImageryLayer",
        "esri/widgets/Legend",
        "esri/widgets/Expand",
        "esri/widgets/Swipe",
        "esri/WebMap",
        "esri/layers/support/RasterFunction",
    ], (Map, MapView, Search, Locate, LayerList, ImageryLayer, Legend, Expand, Swipe, WebMap, RasterFunction) =&amp;gt; {
        //webmap IDs
        const webmapids = [
            "e67a8eb6768641c19d4a7c5df394dbf4", //DTM
            "bfc5b0242adb42bfb0fc41e54497dfc8", //DSM
            "6ed3d2e495db4e859a73d2a32ce3d576", //HEDEM
            "d653b18bc941458491e06e657e10f393", //Intensity
            "a9ab25b1c7204764b2fabad6fc7a4635", //IR
            "e6bab92ebc524072a3305ec8f128e8f8", //Soil
            "2f9acebfb8db4e10bb6dddab8d3239c7", //ClosedDepressions
        ];

        /************************************************************
        * Create multiple WebMap instances
        ************************************************************/
        const webmaps = webmapids.map((webmapid) =&amp;gt; {
            return new WebMap({
                portalItem: {
                    // autocasts as new PortalItem()
                    id: webmapid,
                }
            });
        });

        // add image services used in the swipe map
        const imagery2024 = new ImageryLayer({
            url: "https://gis.willcountyillinois.com/image/rest/services/Orthoimagery/Orthos_2024_3IN/ImageServer",
            rasterFunction: [],
            renderer: {
            type: "raster-stretch", //I added this while debugging: no difference
            }
        });
        webmaps[0].add(imagery2024);

        /************************************************************
         * Initialize the View with the first WebMap
         ************************************************************/
        const view = new MapView({
            map: webmaps[0],
            container: "viewDiv",
            constraints: {
                maxScale: 500,
                minScale: 300000,
            }
        });
        console.log('construct the view')&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 13 Nov 2024 17:11:36 GMT</pubDate>
    <dc:creator>JaredPilbeam2</dc:creator>
    <dc:date>2024-11-13T17:11:36Z</dc:date>
    <item>
      <title>esri.renderers.RasterStretchRenderer - Depreciated - Property: statistics</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/esri-renderers-rasterstretchrenderer-depreciated/m-p/1558135#M86064</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;[esri.renderers.RasterStretchRenderer]  DEPRECATED - Property: statistics 
️ Replacement: customStatistics 
 Version: 4.31&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;I updated my CDN from 4.27 to 4.31 and now I'm getting this warning. I think it's coming from the imagery2024 constructor. I don't have any statistics set in the code as my layers are in webmaps&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;. I'm unsure how to fix it. &lt;A href="https://codepen.io/underjollyroger/pen/MWMvNpZ" target="_self"&gt;Codepen&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;&amp;lt;link rel="stylesheet" href="https://js.arcgis.com/4.31/esri/themes/light/main.css" /&amp;gt;
&amp;lt;script src="https://js.arcgis.com/4.31/"&amp;gt;&amp;lt;/script&amp;gt;

&amp;lt;script&amp;gt;
    require(["esri/Map",
        "esri/views/MapView",
        "esri/widgets/Search",
        "esri/widgets/Locate",
        "esri/widgets/LayerList",
        "esri/layers/ImageryLayer",
        "esri/widgets/Legend",
        "esri/widgets/Expand",
        "esri/widgets/Swipe",
        "esri/WebMap",
        "esri/layers/support/RasterFunction",
    ], (Map, MapView, Search, Locate, LayerList, ImageryLayer, Legend, Expand, Swipe, WebMap, RasterFunction) =&amp;gt; {
        //webmap IDs
        const webmapids = [
            "e67a8eb6768641c19d4a7c5df394dbf4", //DTM
            "bfc5b0242adb42bfb0fc41e54497dfc8", //DSM
            "6ed3d2e495db4e859a73d2a32ce3d576", //HEDEM
            "d653b18bc941458491e06e657e10f393", //Intensity
            "a9ab25b1c7204764b2fabad6fc7a4635", //IR
            "e6bab92ebc524072a3305ec8f128e8f8", //Soil
            "2f9acebfb8db4e10bb6dddab8d3239c7", //ClosedDepressions
        ];

        /************************************************************
        * Create multiple WebMap instances
        ************************************************************/
        const webmaps = webmapids.map((webmapid) =&amp;gt; {
            return new WebMap({
                portalItem: {
                    // autocasts as new PortalItem()
                    id: webmapid,
                }
            });
        });

        // add image services used in the swipe map
        const imagery2024 = new ImageryLayer({
            url: "https://gis.willcountyillinois.com/image/rest/services/Orthoimagery/Orthos_2024_3IN/ImageServer",
            rasterFunction: [],
            renderer: {
            type: "raster-stretch", //I added this while debugging: no difference
            }
        });
        webmaps[0].add(imagery2024);

        /************************************************************
         * Initialize the View with the first WebMap
         ************************************************************/
        const view = new MapView({
            map: webmaps[0],
            container: "viewDiv",
            constraints: {
                maxScale: 500,
                minScale: 300000,
            }
        });
        console.log('construct the view')&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 13 Nov 2024 17:11:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/esri-renderers-rasterstretchrenderer-depreciated/m-p/1558135#M86064</guid>
      <dc:creator>JaredPilbeam2</dc:creator>
      <dc:date>2024-11-13T17:11:36Z</dc:date>
    </item>
    <item>
      <title>Re: esri.renderers.RasterStretchRenderer - Depreciated - Property: statistics</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/esri-renderers-rasterstretchrenderer-depreciated/m-p/1558797#M86072</link>
      <description>&lt;P&gt;Hi there,&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;You needn't worry about these errors since your code does not touch statistics. This will be updated in the MapViewer in coming release.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Nov 2024 18:37:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/esri-renderers-rasterstretchrenderer-depreciated/m-p/1558797#M86072</guid>
      <dc:creator>UndralBatsukh</dc:creator>
      <dc:date>2024-11-14T18:37:14Z</dc:date>
    </item>
  </channel>
</rss>

