vestacrystparser.convert

Create VESTA files from structural data files (POSCAR, etc.).

vestacrystparser.convert.vesta_from_chgcar(fname: str, n: float = 2) VestaFile

Return a VestaFile from VASP CHGCAR.

Isosurface level is determined by (Vesta Manual section 16.7)

\[d(iso) = \langle \vert \rho \vert \rangle + n \times \sigma(\vert \rho \vert)\]

A caution, though. It would appear that VESTA uses a slightly strange method of calculating the standard deviation. As such, the isosurface level set by this method may be off by an amount (e.g. 5%).

Parameters:
  • fname – Filename of the CHGCAR

  • n – Parameter for setting the default isosurface level.

vestacrystparser.convert.vesta_from_poscar(fname: str) VestaFile

Return a VestaFile from a POSCAR file at fname

vestacrystparser.convert.vesta_from_structure(stru: Structure) VestaFile

Return a VestaFile from pymatgen.core.Structure

vestacrystparser.convert.vesta_from_volumetric(volu: VolumetricData, fname: str, n: float = 2, chgcar_like: bool = True) VestaFile

Return a VestaFile from pymatgen VolumetricData

Assumes the Volumetric data is in units of Angstrom, not Bohr.

Isosurface level is determined by (Vesta Manual section 16.7)

\[d(iso) = \langle \vert \rho \vert \rangle + n \times \sigma(\vert \rho \vert)\]
Parameters:
  • volu – VolumetricData object, with structure and volumetric data

  • fname – Filename where the volumetric data lives.

  • n – Parameter for setting the default isosurface level.

  • chgcar_like – If True, divides out the volume.