Code documentation

Modules

elementMass.elements.calculate_weight(compound: str) float[source]

Get the atomic mass of a compound or element

Parameters:

compound (str) – chemical notation of a compound or element

Returns:

weight in atomic mass units

Return type:

float

elementMass.elements.cation_names(compounds: List[str]) List[source]

Get the name of the first cation in a compound

Parameters:

compound (list of str) – chemical notation of compounds or elements

Returns:

names of cations

Return type:

list

elementMass.elements.cation_numbers(compounds: List[str]) Series[source]

Get the cation amount in compounds

Parameters:

compound (list of str) – chemical notation of compounds or elements

Returns:

number of cations in each compound

Return type:

pandas.Series

elementMass.elements.compound_weights(compounds: List[str]) Series[source]

Get the atomic mass of a compounds or elements

Parameters:

compound (list of str) – chemical notation of compounds or elements

Returns:

weights in atomic mass units

Return type:

pandas.Series

elementMass.elements.oxygen_numbers(compounds: List[str]) Series[source]

Get the oxygen amount in compounds

Parameters:

compound (list of str) – chemical notation of compounds or elements

Returns:

number of oxygen in each compound

Return type:

pandas.Series