Wellplate

class chemotion_api.elements.wellplate.Wellplate(generic_segments: GenericSegments, session: Connection, json_data: dict | None = None, id: int | None = None, element_type: str | None = None)

Wellplates represent the localization of materials (chemicals) for biological experiments and are therefore some kind of link between chemical and biological operations. It extends the chemotion_api.elements.abstract_element.AbstractElement

  • Plate size: 12 x 8

  • Verical indexing: 0-11

  • Horiconcal indexing: ‘A’ - ‘H’

Usage:

>>> from chemotion_api import Instance
>>> from chemotion_api.collection import Collection
>>> import logging
>>> try:
>>>     instance = Instance('http(d)://xxx.xxx.xxx').test_connection().login('<USER>', "<PASSWORD>")
>>> except ConnectionError as e:
>>>     logging.error(f"A connection to Chemotion ({instance.host_url}) cannot be established")
>>> # Get the reaction with ID 1
>>> wp = instance.get_wellplate(1)
>>> # Add samples to wellplate
>>> wp.wells[0]['A'] = instance.get_sample(1)
>>> wp.wells[0]['B'] = instance.get_sample(1)
>>> wp.wells[0]['C'] = instance.get_sample(1)
>>> wp.wells[1]['A'] = instance.get_sample(2)
>>> wp.wells[1]['B'] = instance.get_sample(2)
>>> wp.wells[1]['C'] = instance.get_sample(2)
>>> wp.save()
save()

Saves or creates an object according to the set properties. It overwrites the json_data entries by the values set in the segments object.

Raises:
  • RequestException – If request was not successful

  • jsonschema.exceptions.ValidationError – If the properties ar not valid