scipp.merge#

scipp.merge(lhs: scipp._scipp.core.Dataset, rhs: scipp._scipp.core.Dataset) scipp._scipp.core.Dataset#
scipp.merge(lhs: scipp.core.data_group.DataGroup, rhs: scipp.core.data_group.DataGroup) scipp.core.data_group.DataGroup

Merge two datasets or data groups into one.

If an item appears in both inputs, it must have an identical value in both.

Parameters
  • lhs – First dataset or data group.

  • rhs – Second dataset or data group.

Returns

A new object that contains the union of all data items, coords, masks and attributes.

Raises

scipp.DatasetError – If there are conflicting items with different content.