公告:凡是在
2025 年 4 月 15 日前註冊使用 Earth Engine 的非商業專案,都必須
驗證非商業用途資格,才能繼續存取 Earth Engine。
ui.Chart.feature.byProperty
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
從一組特徵產生圖表。繪製一或多個特徵的屬性值。
- X 軸 = 屬性名稱,由 xProperties 標示 (預設:所有屬性)。
- Y 軸 = 屬性值 (必須是數值)。
- 序列 = 特徵,由 seriesProperty 標示 (預設為「system:index」)。
根據預設,除了 seriesProperty 以外的所有屬性都會顯示在 x 軸上。
傳回圖表。
用量 | 傳回 |
---|
ui.Chart.feature.byProperty(features, xProperties, seriesProperty) | ui.Chart |
引數 | 類型 | 詳細資料 |
---|
features | Feature|FeatureCollection|List<Feature> | 要納入圖表的功能。 |
xProperties | List<String>|Object|String,選用 | (1) 要繪製在 x 軸上的屬性;(2) 要繪製在 x 軸上的屬性清單;或 (3) (屬性、標籤) 字典,指定要用做 x 軸值的屬性標籤。如果省略,系統會在 x 軸上繪製所有屬性,並標示名稱。 |
seriesProperty | 字串 (選用) | 用於標示圖例中每個特徵的屬性名稱。預設值為「system:index」。 |
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-07-25 (世界標準時間)。
[null,null,["上次更新時間:2025-07-25 (世界標準時間)。"],[[["\u003cp\u003eGenerates a chart that visualizes the property values of one or more features, plotting them on the y-axis against property names on the x-axis.\u003c/p\u003e\n"],["\u003cp\u003eUsers can customize the chart by specifying which properties to display on the x-axis using \u003ccode\u003exProperties\u003c/code\u003e and how to label each feature in the legend using \u003ccode\u003eseriesProperty\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eBy default, the chart includes all properties except the \u003ccode\u003eseriesProperty\u003c/code\u003e on the x-axis and labels features using their 'system:index'.\u003c/p\u003e\n"],["\u003cp\u003eThe function \u003ccode\u003eui.Chart.feature.byProperty()\u003c/code\u003e takes a Feature, FeatureCollection, or List of features as input and returns a \u003ccode\u003eui.Chart\u003c/code\u003e object.\u003c/p\u003e\n"]]],[],null,["# ui.Chart.feature.byProperty\n\n\u003cbr /\u003e\n\nGenerates a Chart from a set of features. Plots property values of one or more features.\n\n\u003cbr /\u003e\n\n- X-axis = Property name, labeled by xProperties (default: all properties).\n\n- Y-axis = Property value (must be numeric).\n\n- Series = Features, labeled by seriesProperty (default: 'system:index').\n\nAll properties except seriesProperty are included on the x-axis by default.\n\nReturns a chart.\n\n| Usage | Returns |\n|-------------------------------------------------------------------------------|----------|\n| `ui.Chart.feature.byProperty(features, `*xProperties* `, `*seriesProperty*`)` | ui.Chart |\n\n| Argument | Type | Details |\n|------------------|---------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `features` | Feature\\|FeatureCollection\\|List\\\u003cFeature\\\u003e | The features to include in the chart. |\n| `xProperties` | List\\\u003cString\\\u003e\\|Object\\|String, optional | One of (1) a property to be plotted on the x-axis; (2) a list of properties to be plotted on the x-axis; or (3) a (property, label) dictionary specifying labels for properties to be used as values on the x-axis. If omitted, all properties will be plotted on the x-axis, labeled with their names. |\n| `seriesProperty` | String, optional | The name of the property used to label each feature in the legend. Defaults to 'system:index'. |"]]