show_atoms#
- abtem.visualize.visualizations.show_atoms(atoms, plane='xy', ax=None, scale=0.75, title=None, numbering=False, show_periodic=False, figsize=None, legend=False, merge=0.01, tight_limits=False, show_cell=None, **kwargs)[source]#
Display 2D projection of atoms as a matplotlib plot.
- Parameters:
atoms (ase.Atoms) – The atoms to be shown.
plane (str, two float) – The projection plane given as a concatenation of ‘x’ ‘y’ and ‘z’, e.g. ‘xy’, or as two floats representing the azimuth and elevation angles of the viewing direction [degrees], e.g. (45, 45).
ax (matplotlib.axes.Axes, optional) – If given the plots are added to the axes.
scale (float) – Factor scaling their covalent radii for the atom display sizes (default is 0.75).
title (str) – Title of the displayed image. Default is None.
numbering (bool) – Display the index of the Atoms as a number. Default is False.
show_periodic (bool) – If True, show the periodic images of the atoms at the cell boundary.
figsize (two int, optional) – The figure size given as width and height in inches, passed to matplotlib.pyplot.figure.
legend (bool) – If True, add a legend indicating the color of the atomic species.
merge (float) – To speed up plotting large numbers of atoms, those closer than the given value [Å] are merged.
tight_limits (bool) – If True the limits of the plot are adjusted
kwargs (Keyword arguments for matplotlib.collections.PatchCollection.) –
- Return type:
matplotlib.figure.Figure, matplotlib.axes.Axes