chemcoord.Cartesian._preserve_bonds

Cartesian._preserve_bonds(sliced_cartesian, use_lookup=None)

Is called after cutting geometric shapes.

If you want to change the rules how bonds are preserved, when
applying e.g. Cartesian.cut_sphere() this is the function you have to modify.
It is recommended to inherit from the Cartesian class to
tailor it for your project, instead of modifying the source code of ChemCoord.
Parameters:
  • sliced_frame (Cartesian) –
  • use_lookup (bool) – Use a lookup variable for get_bonds(). The default is specified in settings['defaults']['use_lookup']
Returns:

Return type:

Cartesian