ee.FeatureCollection.first

Renvoie la première entrée d'une collection donnée.

UtilisationRenvoie
FeatureCollection.first()Élément
ArgumentTypeDétails
ceci : collectionFeatureCollectionCollection à partir de laquelle sélectionner la première entrée.

Exemples

Éditeur de code (JavaScript)

// A global power plant FeatureCollection.
var fc = ee.FeatureCollection('WRI/GPPD/power_plants');

print('The first feature (power plant) in the collection', fc.first());

Configuration de Python

Consultez la page Environnement Python pour en savoir plus sur l'API Python et sur l'utilisation de geemap pour le développement interactif.

import ee
import geemap.core as geemap

Colab (Python)

from pprint import pprint

# A global power plant FeatureCollection.
fc = ee.FeatureCollection('WRI/GPPD/power_plants')

print('The first feature (power plant) in the collection:')
pprint(fc.first().getInfo())