conformers
- class isicle.conformers.ConformationalEnsemble(*args)[source]
Collection of
Geometry, or related subclass, instances.- _abc_impl = <_abc._abc_data object>
- _apply_function(func, **kwargs)[source]
Process conformational ensemble members according to supplied function.
- Parameters:
func (function) – Function by which ensemble members will be processed.
kwargs – Keyword arguments passed to func.
- Returns:
Result of operation, type depends on func return type.
- Return type:
ConformationalEnsembleor list
- _apply_method(method, **kwargs)[source]
Process conformational ensemble members according to supplied method.
- Parameters:
method (str) – Method by which ensemble members will be processed.
kwargs – Keyword arguments passed to method.
- Returns:
Result of operation, type depends on method return type.
- Return type:
ConformationalEnsembleor list
- _check_attributes(attr)[source]
Check if all ensemble members have the supplied attribute.
- Parameters:
attr (str) – Attribute to check.
- Raises:
AttributeError – If all members do not have attr.
- apply(func=None, method=None, **kwargs)[source]
Process conformational ensemble members according to supplied function or method.
- Parameters:
func (function) – Function by which ensemble members will be processed.
method (str) – Method by which ensemble members will be processed.
kwargs – Keyword arguments passed to method.
- Returns:
Result of operation, type depends on method return type.
- Return type:
ConformationalEnsembleor list- Raises:
ValueError – If neither func nor method is supplied.
- get_structures()[source]
Extract all structures from containing object as a conformational ensemble.
- Returns:
Conformational ensemble.
- Return type:
- reduce(attr, func='boltzmann', **kwargs)[source]
Combine attribute values according to indicated function.
- Parameters:
attr (str) – Attribute that will be combined.
func (str) – Alias for function selection (one of “boltzmann”, “simple”, “lowest”, or “threshold”).
kwargs – Additional keyword arguments passed to func.
- Returns:
Result of reduction operation.
- Return type:
DataFrame
- isicle.conformers._energy_based(func)[source]
Checks whether function employs an energy-based reduction operation.
- Parameters:
func (function) – Conformer reduction function.
- Returns:
True if energy based, otherwise False.
- Return type:
bool
- isicle.conformers._function_selector(func)[source]
Selects a supported reduction function for reducing a set of conformers.
- Parameters:
func (str) – Alias for function selection (one of “boltzmann”, “simple”, “lowest”, or “threshold”).
- Returns:
Conformer reduction function.
- Return type:
func
- isicle.conformers.boltzmann(value, energy, index=None, atom=None)[source]
Combine values according to a Boltzmann-weighted average.
- Parameters:
value (
array) – Array containing values that will be combined.energy (
array) – Array containing energy values that correspond to entries in value.index (None or
array) – Index by which to group values for averaging.atom (None or
array) – Atom by which to group values for averaging.
- Returns:
Result of reduction operation.
- Return type:
DataFrame
- isicle.conformers.build_conformational_ensemble(geometries)[source]
Create a conformational ensemble from a collection of geometries.
- Parameters:
geometries (list of
Geometryor related subclass) – Collection of geometry instances.- Returns:
Conformational ensemble.
- Return type:
- isicle.conformers.energy_threshold(value, energy, threshold=5, index=None, atom=None)[source]
Combine values with energy below a given threshold according to a simple average.
- Parameters:
value (
array) – Array containing values that will be combined.energy (
array) – Array containing energy values that correspond to entries in value.index (None or
array) – Index by which to group values for averaging.atom (None or
array) – Atom by which to group values for averaging.
- Returns:
Result of reduction operation.
- Return type:
DataFrame
- isicle.conformers.lowest_energy(value, energy, index=None, atom=None)[source]
Combine values according to lowest energy.
- Parameters:
value (
array) – Array containing values that will be combined.energy (
array) – Array containing energy values that correspond to entries in value.index (None or
array) – Index by which to group values for averaging.atom (None or
array) – Atom by which to group values for averaging.
- Returns:
Result of reduction operation.
- Return type:
DataFrame
- isicle.conformers.reduce(value, func='boltzmann', **kwargs)[source]
Combine values according to indicated function.
- Parameters:
value (
array) – Array containing values that will be combined.func (str) – Alias for function selection (one of “boltzmann”, “simple”, “lowest”, or “threshold”).
kwargs – Additional keyword arguments passed to func.
- Returns:
Result of reduction operation.
- Return type:
DataFrame
- isicle.conformers.simple_average(value, index=None, atom=None)[source]
Combine values according to a simple average.
- Parameters:
value (
array) – Array containing values that will be combined.index (None or
array) – Index by which to group values for averaging.atom (None or
array) – Atom by which to group values for averaging.
- Returns:
Result of reduction operation.
- Return type:
DataFrame
- isicle.conformers.transform(value, m={'C': 1.0, 'H': 1.0}, b={'C': 0.0, 'H': 0.0}, index=None, atom=None)[source]
Perform linear transformation with values using provided parameters.
- Parameters:
value – Array containing vales that will be transformed.
m (float or dict) – Slope value
b (float or dict) – Y-intercept value
index (None or :obj: ~numpy.array) – Index by which to group values for transforming.
atom (None or :obj: ~numpy.array) – Atom by which to group values for transforming.
- Returns:
Result of transformation operation.
- Return type:
obj: ~pandas.DataFrame