MCPcopy Index your code
hub / github.com/pydata/xarray / normalize

Method normalize

xarray/core/accessor_str.py:832–852  ·  view source on GitHub ↗

Return the Unicode normal form for the strings in the datarray. For more information on the forms, see the documentation for :func:`unicodedata.normalize`. Parameters ---------- form : {"NFC", "NFKC", "NFD", "NFKD"} Unicode form.

(
        self,
        form: str,
    )

Source from the content-addressed store, hash-verified

830 return self._apply(func=lambda x: x.casefold())
831
832 def normalize(
833 self,
834 form: str,
835 ) -> T_DataArray:
836 """
837 Return the Unicode normal form for the strings in the datarray.
838
839 For more information on the forms, see the documentation for
840 :func:`unicodedata.normalize`.
841
842 Parameters
843 ----------
844 form : {"NFC", "NFKC", "NFD", "NFKD"}
845 Unicode form.
846
847 Returns
848 -------
849 normalized : same type as values
850
851 """
852 return self._apply(func=lambda x: normalize(form, x)) # type: ignore[arg-type]
853
854 def isalnum(self) -> T_DataArray:
855 """

Callers 2

is_valid_nc3_nameFunction · 0.80
test_case_strFunction · 0.80

Calls 1

_applyMethod · 0.95

Tested by 1

test_case_strFunction · 0.64