From 55fce08c6cbec020f681fa9eb6c7db905feecb4b Mon Sep 17 00:00:00 2001 From: Jason Munro Date: Thu, 25 Mar 2021 10:12:16 -0700 Subject: [PATCH] nelements added to general min max filter --- src/mp_api/materials/query_operators.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/mp_api/materials/query_operators.py b/src/mp_api/materials/query_operators.py index 3ad173d9..c8ac7af1 100644 --- a/src/mp_api/materials/query_operators.py +++ b/src/mp_api/materials/query_operators.py @@ -80,6 +80,12 @@ def query( nsites_min: Optional[int] = Query( None, description="Minimum value for the number of sites", ), + nelements_max: Optional[float] = Query( + None, description="Maximum value for the number of elements.", + ), + nelements_min: Optional[float] = Query( + None, description="Minimum value for the number of elements.", + ), volume_max: Optional[float] = Query( None, description="Maximum value for the cell volume", ), @@ -98,6 +104,7 @@ def query( entries = { "nsites": [nsites_min, nsites_max], + "nelements": [nelements_min, nelements_max], "volume": [volume_min, volume_max], "density": [density_min, density_max], } # type: dict