Skip to main content

Thank you for visiting You are using a browser version with limited support for CSS. To obtain the best experience, we recommend you use a more up to date browser (or turn off compatibility mode in Internet Explorer). In the meantime, to ensure continued support, we are displaying the site without styles and JavaScript.

Using collective knowledge to assign oxidation states of metal cations in metal–organic frameworks


Knowledge of the oxidation state of metal centres in compounds and materials helps in the understanding of their chemical bonding and properties. Chemists have developed theories to predict oxidation states based on electron-counting rules, but these can fail to describe oxidation states in extended crystalline systems such as metal–organic frameworks. Here we propose the use of a machine-learning model, trained on assignments by chemists encoded in the chemical names in the Cambridge Structural Database, to automatically assign oxidation states to the metal ions in metal–organic frameworks. In our approach, only the immediate local environment around a metal centre is considered. We show that the strategy is robust to experimental uncertainties such as incorrect protonation, unbound solvents or changes in bond length. This method gives good accuracy and we show that it can be used to detect incorrect assignments in the Cambridge Structural Database, illustrating how collective knowledge can be captured by machine learning and converted into a useful tool.

Access options

Rent or Buy article

Get time limited or full article access on ReadCube.


All prices are NET prices.

Fig. 1: Schematic representation of the featurization approach.
Fig. 2: Performance metrics for the assignment of oxidation states of Cu in MOFs.
Fig. 3: First two principal components for Cu sites.
Fig. 4: Predictive performance across the periodic table.
Fig. 5: Predictions of the oxidation states in mixed-valence MOF Cu(i/ii)–BTC.
Fig. 6: Predictions of the oxidation states in MIL-47 before (as-synthesized) and after activation.

Data availability

The feature matrices, labels and a pretrained model are deposited on the Materials Cloud archive ( The data that reproduce the plots shown in the main text can be found in a Code Ocean Capsule (

Code availability

Predictions for MOF structures can be performed using the oximachinerunner Python package (, which can be installed from PyPi. The code for parsing, featurization as well for the ML models is available on GitHub ( and and deposited on Zenodo (10.5281/zenodo.3567011, 10.5281/zenodo.3567274). The web app is hosted on the work section of Materials Cloud ( The code for this app, along with a Dockerfile, is also available on GitHub ( and deposited on Zenodo (10.5281/zenodo.3603606). The code used to generate the plots shown in the main text can be found in a Code Ocean capsule ( The code used to generate the structure graphics in the graphical abstract is available in ref. 67.


  1. 1.

    Walsh, A., Sokol, A. A., Buckeridge, J., Scanlon, D. O. & Catlow, C. R. A. Oxidation states and ionicity. Nat. Mater. 17, 958–964 (2018).

    CAS  PubMed  Google Scholar 

  2. 2.

    Jensen, W. B. The origin of the oxidation-state concept. J. Chem. Educ. 84, 1418 (2007).

    CAS  Google Scholar 

  3. 3.

    Wöhler, F. Grundriss Der Chemie: Unorganische Chemie 3rd edn, 4 (Duncker & Humblot, 1835).

  4. 4.

    Latimer, W. M. The Oxidation States of the Elements and Their Potentials in Aqueous Solutions (Prentice-Hall Chemistry Series) 2nd edn (Prentice-Hall, 1952).

    Google Scholar 

  5. 5.

    Connelly, N. G., Damhus, T., Hartshorn, R. M. & Hutton, A. T. (eds.) Nomenclature of Inorganic Chemistry. IUPAC Recommendations 2005 (RSC and IUPAC, 2005).

  6. 6.

    Kroll, J. H. et al. Carbon oxidation state as a metric for describing the chemistry of atmospheric organic aerosol. Nat. Chem. 3, 133–139 (2011).

    CAS  PubMed  Google Scholar 

  7. 7.

    Terrett, J. A., Cuthbertson, J. D., Shurtleff, V. W. & MacMillan, D. W. C. Switching on elusive organometallic mechanisms with photoredox catalysis. Nature 524, 330–334 (2015).

    CAS  PubMed  PubMed Central  Google Scholar 

  8. 8.

    Jørgensen, C. K. Oxidation Numbers and Oxidation States (Springer, 1969).

  9. 9.

    Ball, P. Beyond the bond. Nature 469, 26–28 (2011).

    CAS  PubMed  Google Scholar 

  10. 10.

    Gold, V. (ed.) The IUPAC Compendium of Chemical Terminology: The Gold Book (IUPAC, 2019);

  11. 11.

    Karen, P., McArdle, P. & Takats, J. Comprehensive definition of oxidation state (IUPAC recommendations 2016). Pure Appl. Chem. 88, 831–839 (2016).

    CAS  Google Scholar 

  12. 12.

    Brown, I. D. Recent developments in the methods and applications of the bond valence model. Chem. Rev. 109, 6858–6919 (2009).

    CAS  PubMed  PubMed Central  Google Scholar 

  13. 13.

    Pauling, L. Atomic radii and interatomic distances in metals. J. Am. Chem. Soc. 69, 542–553 (1947).

    CAS  Google Scholar 

  14. 14.

    Shields, G. P., Raithby, P. R., Allen, F. H. & Motherwell, W. D. S. The assignment and validation of metal oxidation states in the Cambridge Structural Database. Acta Crystallogr. B 56, 455–465 (2000).

    PubMed  Google Scholar 

  15. 15.

    Reeves, M. G., Wood, P. A. & Parsons, S. Automated oxidation-state assignment for metal sites in coordination complexes in the Cambridge Structural Database. Acta Crystallogr. B 75, 1096–1105 (2019).

    CAS  Google Scholar 

  16. 16.

    Taylor, R. & Wood, P. A. A million crystal structures: the whole is greater than the sum of its parts. Chem. Rev. 119, 9427–9477 (2019).

    CAS  PubMed  Google Scholar 

  17. 17.

    O’Keeffe, M. A proposed rigorous definition of coordination number. Acta Crystallogr. A 35, 772–775 (1979).

    Google Scholar 

  18. 18.

    Walsh, A., Sokol, A. A., Buckeridge, J., Scanlon, D. O. & Catlow, C. R. A. Electron counting in solids: oxidation states, partial charges, and ionicity. J. Phys. Chem. Lett. 8, 2074–2075 (2017).

    CAS  PubMed  Google Scholar 

  19. 19.

    Pan, H. et al. Benchmarking coordination number prediction algorithms on inorganic crystal structures. Inorg. Chem. 60, 1590–1603 (2021).

    CAS  PubMed  Google Scholar 

  20. 20.

    Conry, R. R. in Encyclopedia of Inorganic Chemistry (eds King, R. B. et al.) (Wiley, 2006).

  21. 21.

    Wang, L., Maxisch, T. & Ceder, G. Oxidation energies of transition metal oxides within the GGA + U framework. Phys. Rev. B 73, 195107 (2006).

    Google Scholar 

  22. 22.

    Stevanović, V., Lany, S., Zhang, X. & Zunger, A. Correcting density functional theory for accurate predictions of compound enthalpies of formation: fitted elemental-phase reference energies. Phys. Rev. B 85, 115104 (2012).

    Google Scholar 

  23. 23.

    Raebiger, H., Lany, S. & Zunger, A. Charge self-regulation upon changing the oxidation state of transition metals in insulators. Nature 453, 763–766 (2008).

    CAS  PubMed  Google Scholar 

  24. 24.

    Bendix, J., Brorson, M. & Schäffer, C. E. in Coordination Chemistry Vol. 565 (ed. Kauffman, G. B.) 213–225 (American Chemical Society, 1994).

  25. 25.

    Jansen, M. & Wedig, U. A piece of the picture-misunderstanding of chemical concepts. Angew. Chem. Int. Ed. 47, 10026–10029 (2008).

    CAS  Google Scholar 

  26. 26.

    Groom, C. R., Bruno, I. J., Lightfoot, M. P. & Ward, S. C. The Cambridge Structural Database. Acta Crystallogr. B 72, 171–179 (2016).

    CAS  Google Scholar 

  27. 27.

    Holgate, S. CSD data curation – the human touch. The Cambridge Crystallographic Data Centre (2019).

  28. 28.

    Allen, F. H. & Taylor, R. Research applications of the Cambridge Structural Database (CSD). Chem. Soc. Rev. 33, 463–475 (2004).

    CAS  PubMed  Google Scholar 

  29. 29.

    Bürgi, H.-B. & Dunitz, J. D. (eds) Structure Correlation (Wiley, 1994).

  30. 30.

    Jablonka, K. M., Ongari, D., Moosavi, S. M. & Smit, B. Big-data science in porous materials: materials genomics and machine learning. Chem. Rev. 120, 8066–8129 (2020).

    CAS  PubMed  PubMed Central  Google Scholar 

  31. 31.

    Janet, J. P. & Kulik, H. J. Resolving transition metal chemical space: feature selection for machine learning and structure–property relationships. J. Phys. Chem. A 121, 8939–8954 (2017).

    CAS  PubMed  Google Scholar 

  32. 32.

    Pauling, L. The principles determining the structure of complex ionic crystals. J. Am. Chem. Soc. 51, 1010–1026 (1929).

    CAS  Google Scholar 

  33. 33.

    Prodan, E. & Kohn, W. Nearsightedness of electronic matter. Proc. Natl Acad. Sci. USA 102, 11635–11638 (2005).

    CAS  PubMed  PubMed Central  Google Scholar 

  34. 34.

    Baur, W. H. Bond length variation and distorted coordination polyhedra in inorganic crystals. Trans. Am. Crystallogr. Assoc. 6, 129–155 (1970).

    CAS  Google Scholar 

  35. 35.

    George, J. et al. The limited predictive power of the Pauling rules. Angew. Chem. Int. Ed. 59, 7569–7575 (2020).

    CAS  Google Scholar 

  36. 36.

    Müller, P., Köpke, S. & Sheldrick, G. M. Is the bond-valence method able to identify metal atoms in protein structures? Acta Crystallogr. D 59, 32–37 (2003).

    PubMed  Google Scholar 

  37. 37.

    Harvey, M. A., Baggio, S. & Baggio, R. A new simplifying approach to molecular geometry description: the vectorial bond-valence model. Acta Crystallogr. A 62, 1038–1042 (2006).

    CAS  Google Scholar 

  38. 38.

    Brown, I. D. View of lone electron pairs and their role in structural chemistry. J. Phys. Chem. A 115, 12638–12645 (2011).

    CAS  PubMed  Google Scholar 

  39. 39.

    Liu, S., Grinberg, I., Takenaka, H. & Rappe, A. M. Reinterpretation of the bond-valence model with bond-order formalism: an improved bond-valence-based interatomic potential for PbTiO3. Phys. Rev. B 88, 104102 (2013).

    Google Scholar 

  40. 40.

    Jahn, H. & Teller, E. Stability of polyatomic molecules in degenerate electronic states - I—Orbital degeneracy. Proc. R. Soc. Lond. A 161, 220–235 (1937).

    CAS  Google Scholar 

  41. 41.

    Gillespie, R. J. & Hargittai, I. The VSEPR Model of Molecular Geometry (Dover Publications, 2012).

  42. 42.

    Zimmermann, N. E. R., Horton, M. K., Jain, A. & Haranczyk, M. Assessing local structure motifs using order parameters for motif recognition, interstitial identification, and diffusion path characterization. Front. Mater. 4, 34 (2017).

    Google Scholar 

  43. 43.

    Davies, D. W., Butler, K. T., Isayev, O. & Walsh, A. Materials discovery by chemical analogy: role of oxidation states in structure prediction. Faraday Discuss. 211, 553–568 (2018).

    CAS  PubMed  Google Scholar 

  44. 44.

    Ward, L. et al. Including crystal structure attributes in machine learning models of formation energies via Voronoi tessellations. Phys. Rev. B 96, 024104 (2017).

    Google Scholar 

  45. 45.

    Rokach, L. Ensemble-based classifiers. Artif. Intell. Rev. 33, 1–39 (2010).

    Google Scholar 

  46. 46.

    Ahmed, A. et al. Cu(I)Cu(II)BTC, a microporous mixed-valence MOF via reduction of HKUST-1. RSC Adv. 6, 8902–8905 (2016).

    CAS  Google Scholar 

  47. 47.

    Lundberg, S. M. & Lee, S.-I. A unified approach to interpreting model predictions. In Advances in Neural Information Processing Systems 30 (eds Guyon, I. et al.) 4765–4774 (Curran Associates, 2017).

  48. 48.

    Molnar, C. Interpretable Machine Learning: A Guide for making Black Box Models Interpretable (Leanpub, 2020);

  49. 49.

    Barthelet, K., Marrot, J., Riou, D. & Férey, G. A breathing hybrid organic–inorganic solid with very large pores and high magnetic characteristics. Angew. Chem. Int. Ed. 41, 281–284 (2002).

    CAS  Google Scholar 

  50. 50.

    Centrone, A., Harada, T., Speakman, S. & Hatton, T. A. Facile synthesis of vanadium metal–organic frameworks and their magnetic properties. Small 6, 1598–1602 (2010).

    CAS  PubMed  Google Scholar 

  51. 51.

    Leclerc, H. et al. Influence of the oxidation state of the metal center on the flexibility and adsorption properties of a porous metal organic framework: MIL-47(V). J. Phys. Chem. C 115, 19828–19840 (2011).

    CAS  Google Scholar 

  52. 52.

    Kozachuk, O. et al. A solid-solution approach to mixed-metal metal–organic frameworks – detailed characterization of local structures, defects and breathing behaviour of Al/V frameworks. Eur. J. Inorg. Chem. 2013, 4546–4557 (2013).

    CAS  Google Scholar 

  53. 53.

    Krakowiak, J., Lundberg, D. & Persson, I. A coordination chemistry study of hydrated and solvated cationic vanadium ions in oxidation states +III, +IV, and +V in solution and Solid State. Inorg. Chem. 51, 9598–9609 (2012).

    CAS  PubMed  PubMed Central  Google Scholar 

  54. 54.

    Bloch, E. D. et al. Selective binding of O2 over N2 in a redox–active metal–organic framework with open iron(II) coordination sites. J. Am. Chem. Soc. 133, 14814–14822 (2011).

    CAS  PubMed  Google Scholar 

  55. 55.

    Jain, A. et al. Commentary: the Materials Project: a materials genome approach to accelerating materials innovation. APL Mater. 1, 011002 (2013).

    Google Scholar 

  56. 56.

    Janet, J. P. & Kulik, H. J. Predicting electronic structure properties of transition metal complexes with neural networks. Chem. Sci. 8, 5137–5152 (2017).

    CAS  PubMed  PubMed Central  Google Scholar 

  57. 57.

    Ongari, D., Yakutovich, A. V., Talirz, L. & Smit, B. Building a consistent and reproducible database for adsorption vvaluation in covalent–organic frameworks. ACS Cent. Sci. 5, 1663–1675 (2019).

    CAS  PubMed  PubMed Central  Google Scholar 

  58. 58.

    Jiang, L., Levchenko, S. V. & Rappe, A. M. Rigorous definition of oxidation states of ions in solids. Phys. Rev. Lett. 108, 166403 (2012).

    PubMed  Google Scholar 

  59. 59.

    Moghadam, P. Z. et al. Development of a Cambridge Structural Database subset: a collection of metal–organic frameworks for past, present, and future. Chem. Mater. 29, 2618–2625 (2017).

    CAS  Google Scholar 

  60. 60.

    Ward, L. et al. Matminer: an open source toolkit for materials data mining. Comput. Mater. Sci. 152, 60–69 (2018).

    Google Scholar 

  61. 61.

    Pedregosa, F. et al. Scikit-learn: machine learning in Python. J. Mach. Learn. Res. 12, 2825–2830 (2011).

    Google Scholar 

  62. 62.

    Komer, B., Bergstra, J. & Eliasmith, C. Hyperopt-sklearn: automatic hyperparameter configuration for Scikit-learn. In Proc. 13th Python in Science Conference (eds van der Walt, S. & Bergstra, J.) 32–37 (SciPy, 2014).

  63. 63.

    Sechidis, K., Tsoumakas, G. & Vlahavas, I. On the stratification of multi-label data. In Machine Learning and Knowledge Discovery in Databases Vol. 6913 (eds Gunopulos, D. et al.) 145–158 (Springer, 2011).

  64. 64.

    Schreiber, J., Bilmes, J. & Noble, W. S. apricot: Submodular selection for data summarization in Python. Preprint at (2019).

  65. 65.

    Momma, K. & Izumi, F. VESTA 3 for three-dimensional visualization of crystal, volumetric and morphology data. J. Appl. Crystallogr. 44, 1272–1276 (2011).

    CAS  Google Scholar 

  66. 66.

    Talirz, L. et al. Materials Cloud, a platform for open computational science. Sci. Data 7, 299 (2020).

  67. 67.

    Dubbeldam, D., Calero, S. & Vlugt, T. J. iRASPA: GPU-accelerated visualization software for materials scientists. Mol. Simul. 44, 653–676 (2018).

    CAS  Google Scholar 

Download references


This work was supported by a European Research Council (ERC) Advanced Grant (Grant Agreement No. 666983, MaGic), the Swiss National Science Foundation (SNSF) under Grant 200021_172759 and the National Center of Competence in Research (NCCR) through the Materials’ Revolution: Computational Design and Discovery of Novel Materials (MARVEL). We thank L. Talirz and the Materials Cloud team for feedback on the web app, the integration into AiiDA workflows for DFT optimization ( and A. Yakutovich for help with the integration in AiiDAlab. Moreover, we are grateful for all the feedback we received from chemists all over the world on the potential errors we found in their CSD entries.

Author information




K.M.J. developed the ML workflows. D.O. carried out the bond valence sum analyses. B.S., S.M.M. and K.M.J. developed the featurization. All authors contributed to the analysis of the data and the writing of the article.

Corresponding author

Correspondence to Berend Smit.

Ethics declarations

Competing interests

The authors declare no competing interests.

Additional information

Peer review information Nature Chemistry thanks Joshua Schrier, Vivek Sinha and the other, anonymous, reviewer(s) for their contribution to the peer review of this work.

Publisher’s note Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Supplementary information

Supplementary Information

Supplementary Figs. 1–36, Discussion, Tables 1–34 and refs. 1–327.

Rights and permissions

Reprints and Permissions

About this article

Verify currency and authenticity via CrossMark

Cite this article

Jablonka, K.M., Ongari, D., Moosavi, S.M. et al. Using collective knowledge to assign oxidation states of metal cations in metal–organic frameworks. Nat. Chem. 13, 771–777 (2021).

Download citation


Quick links

Nature Briefing

Sign up for the Nature Briefing newsletter — what matters in science, free to your inbox daily.

Get the most important science stories of the day, free in your inbox. Sign up for Nature Briefing