bids.variables.merge_variables

merge_variables(variables, name=None, \*\*kwargs)[source]

Merge/concatenate a list of variables along the row axis.

Parameters
  • variables (list) – A list of Variables to merge.

  • name (str) – Optional name to assign to the output Variable. By default, uses the same name as the input variables.

  • kwargs

    Optional keyword arguments to pass onto the class-specific merge() call. Possible args:

    • sampling_rate (int, str): The sampling rate to use if resampling of DenseRunVariables is necessary for harmonization. If ‘auto’, the highest sampling rate found will be used. This argument is only used when passing DenseRunVariables in the variables list.

Returns

Return type

A single BIDSVariable of the same class as the input variables.

Notes

  • Currently, this function only support homogeneously-typed lists. In future, it may be extended to support implicit conversion.

  • Variables in the list must all share the same name (i.e., it is not possible to merge two different variables into a single variable.)