pandahandler.frames.joiners =========================== .. py:module:: pandahandler.frames.joiners .. autoapi-nested-parse:: Methods to join/merge/stack multiple data frames. Functions --------- .. autoapisummary:: pandahandler.frames.joiners.safe_hstack Module Contents --------------- .. py:function:: safe_hstack(frames: list[pandas.DataFrame]) -> pandas.DataFrame Horizontally concatenate (i.e. axis=1) data frames after asserting strong assumptions. The naming of this method suggests an apt analogy with numpy's `hstack` function, which horizontally stacks arrays. This method is a convenience wrapper around `pd.concat` that includes the following assertions about the inputs frames: * all data frames must share the same index * there is no overlap among the columns of the data frames (ignoring the indexes) :param frames: The data frames to concatenate. :raises ValueError: If no data frames are provided in `frames`. :raises ValueError: If the data frames do not all share the same index. :raises ValueError: If any column name appears in more than one of the input data frames.