Skip to main content
`Ctrl`+`K`

# combine_masks

astropy.utils.masked.combine_masks(masks, *, out=None, where=True, copy=True)

  Combine masks, possibly storing it in some output.

  Parameters:
    masks `python:tuple` of `array` of bool or `python:False` or `python:None`

      Input masks. Any that are `None` or `False` are ignored. Should broadcast to each other. For structured dtype, an element is considered masked if any of the fields is.

    out `array`, optional

      Possible output array to hold the result.

    where `array` of bool, optional

      Which elements of the output array to fill.

    copy bool optional

      Whether to ensure a copy is made. Only relevant if just a single input mask is not `None`, and `out` is not given.

  Returns:
    mask `array`

      Combined mask.