🍾 Xarray is now 10 years old! 🎉

xarray.DataArray.str.repeat

xarray.DataArray.str.repeat#

DataArray.str.repeat(repeats)[source]#

Repeat each string in the array.

If repeats is array-like, it is broadcast against the array and applied elementwise.

Parameters:

repeats (int or array-like of int) – Number of repetitions. If array-like, it is broadcast.

Returns:

repeated (same type as values) – Array of repeated string objects.