eugene.dataload.add_obs

eugene.dataload.add_obs(sdata, obs, on=None, left_on=None, right_on=None)

Add observational metadata to a SeqData.

Parameters:
  • sdata (xr.Dataset) – The SeqData to add observations to.

  • obs (pd.DataFrame) – The observations to add.

  • on (str, optional) – The column name to join on. If not given, left_on and right_on must be given.

  • left_on (str, optional) – The column name in the SeqData to join on. If not given, on must be given.

  • right_on (str, optional) – The column name in the observations to join on. If not given, on must be given.

Raises:

ValueError – If on is not given and left_on or right_on are not given. If on is given and left_on or right_on are given.

Return type:

None