ee.FeatureCollection.toList

Bir koleksiyondaki öğeleri liste olarak döndürür.

Kullanımİadeler
FeatureCollection.toList(count, offset)Liste
Bağımsız DeğişkenTürAyrıntılar
bu: collectionFeatureCollectionGetirilecek giriş koleksiyonu.
countTamsayıGetirilecek maksimum öğe sayısı.
offsetTamsayı, varsayılan: 0Başlangıçtan itibaren atılacak öğe sayısı. Ayarlanırsa (ofset + sayı) öğe getirilir ve ilk ofset öğeleri atılır.

Örnekler

Kod Düzenleyici (JavaScript)

// FeatureCollection of power plants in Belgium.
var fc = ee.FeatureCollection('WRI/GPPD/power_plants')
             .filter('country_lg == "Belgium"');

print('First 5 features to an ee.List', fc.toList(5));

print('Second 5 features to an ee.List', fc.toList(5, 5));

Python kurulumu

Python API'si ve etkileşimli geliştirme için geemap kullanımı hakkında bilgi edinmek üzere Python Ortamı sayfasına bakın.

import ee
import geemap.core as geemap

Colab (Python)

# FeatureCollection of power plants in Belgium.
fc = ee.FeatureCollection('WRI/GPPD/power_plants').filter(
    'country_lg == "Belgium"')

print('First 5 features to an ee.List:', fc.toList(5).getInfo())

print('Second 5 features to an ee.List:', fc.toList(5, 5).getInfo())