This new computational method improves our understanding of how microbes organize themselves into communities. It describes in detail how neighboring species affect interactions between microbes. This method also predicts major shifts in microbes’ influence on carbon and nitrogen cycles. This information could enable scientists to design and engineer groups and communities of microbes in the future.