ee.Reducer.fixed2DHistogram
קל לארגן דפים בעזרת אוספים
אפשר לשמור ולסווג תוכן על סמך ההעדפות שלך.
יוצרת פונקציית צמצום שתחשב היסטוגרמה דו-ממדית של נתוני הקלט באמצעות מספר קבוע של תאים ברוחב קבוע. המערכת מתעלמת מערכים מחוץ לטווח [min, max) בכל אחד מהצירים. הפלט הוא מערך דו-ממדי של ספירות, ו-2 מערכים חד-ממדיים של הקצוות התחתונים של משבצות ה-xAxis וה-yAxis. הפונקציה הזו מתאימה לשימוש בכל פיקסל, אבל היא תמיד לא משוקללת. הספירה המקסימלית לכל דלי היא 2^31 - 1.
שימוש | החזרות |
---|
ee.Reducer.fixed2DHistogram(xMin, xMax, xSteps, yMin, yMax, ySteps) | הפחתה |
ארגומנט | סוג | פרטים |
---|
xMin | מספר ממשי (float) | הגבול התחתון (כולל) של הדלי הראשון בציר ה-X. |
xMax | מספר ממשי (float) | הגבול העליון (לא כולל) של הדלי האחרון בציר X. |
xSteps | מספר שלם | מספר האינטרוולים שבהם יש להשתמש בציר X. |
yMin | מספר ממשי (float) | הגבול התחתון (כולל) של הדלי הראשון בציר Y. |
yMax | מספר ממשי (float) | הגבול העליון (לא כולל) של הדלי האחרון בציר Y. |
ySteps | מספר שלם | מספר האינטרוולים שבהם רוצים להשתמש בציר Y. |
אלא אם צוין אחרת, התוכן של דף זה הוא ברישיון Creative Commons Attribution 4.0 ודוגמאות הקוד הן ברישיון Apache 2.0. לפרטים, ניתן לעיין במדיניות האתר Google Developers. Java הוא סימן מסחרי רשום של חברת Oracle ו/או של השותפים העצמאיים שלה.
עדכון אחרון: 2025-07-26 (שעון UTC).
[null,null,["עדכון אחרון: 2025-07-26 (שעון UTC)."],[[["\u003cp\u003eCreates a 2D histogram with a fixed number of bins for analyzing data distribution across two dimensions.\u003c/p\u003e\n"],["\u003cp\u003eIgnores values outside the defined range on either axis and limits the maximum count per bucket to 2^31 - 1.\u003c/p\u003e\n"],["\u003cp\u003eOutputs a 2D array of counts, along with 1D arrays for the x and y axis bucket boundaries.\u003c/p\u003e\n"],["\u003cp\u003eSuitable for per-pixel use but doesn't incorporate weighting.\u003c/p\u003e\n"],["\u003cp\u003eRequires specifying the range and number of bins for both x and y axes using the \u003ccode\u003eee.Reducer.fixed2DHistogram\u003c/code\u003e function.\u003c/p\u003e\n"]]],[],null,["# ee.Reducer.fixed2DHistogram\n\nCreates a reducer that will compute a 2D histogram of the inputs using a fixed number of fixed-width bins. Values outside of the \\[min, max) range on either axis are ignored. The output is a 2D array of counts, and 2 1-D arrays of bucket lower edges for the xAxis and the yAxis. This reducer is suitable for use per-pixel, however it is always unweighted. The maximum count for any bucket is 2\\^31 - 1.\n\n\u003cbr /\u003e\n\n| Usage | Returns |\n|-----------------------------------------------------------------------|---------|\n| `ee.Reducer.fixed2DHistogram(xMin, xMax, xSteps, yMin, yMax, ySteps)` | Reducer |\n\n| Argument | Type | Details |\n|----------|---------|----------------------------------------------------------------|\n| `xMin` | Float | The lower (inclusive) bound of the first bucket on the X axis. |\n| `xMax` | Float | The upper (exclusive) bound of the last bucket on the X axis. |\n| `xSteps` | Integer | The number of buckets to use on the X axis. |\n| `yMin` | Float | The lower (inclusive) bound of the first bucket on the Y axis. |\n| `yMax` | Float | The upper (exclusive) bound of the last bucket on the Y axis. |\n| `ySteps` | Integer | The number of buckets to use on the Y axis. |"]]