Ecosystems as functional units in nature