structuretoolkit.analyse.pyscal.get_steinhardt_parameters

structuretoolkit.analyse.pyscal.get_steinhardt_parameters#

structuretoolkit.analyse.pyscal.get_steinhardt_parameters(structure: Atoms, neighbor_method: str = 'cutoff', cutoff: float = 0.0, n_clusters: int | None = 2, q: tuple | None = None, averaged: bool = False) ndarray | tuple[ndarray, ndarray][source]#

Calculate Steinhardts parameters

Parameters:
  • structure (Atoms) – The structure to analyse.

  • neighbor_method (str) – can be [‘cutoff’, ‘voronoi’]. (Default is ‘cutoff’.)

  • cutoff (float) – Can be 0 for adaptive cutoff or any other value. (Default is 0, adaptive.)

  • n_clusters (int/None) – Number of clusters for K means clustering or None to not cluster. (Default is 2.)

  • q (list) – Values can be integers from 2-12, the required q values to be calculated. (Default is None, which uses (4, 6).)

  • averaged (bool) – If True, calculates the averaged versions of the parameter. (Default is False.)

Returns:

(number of q’s, number of atoms) shaped array of q parameters Tuple[numpy.ndarray]: If clustering=True, an additional per-atom array of cluster ids is also returned

Return type:

Tuple[numpy.ndarray]