(self, c)
return res
Transform the given data.

        Args:
            c (np.array): an array of type that can be cast to dtype `str`

        Returns:
            np.array of floats representing indices of matched patterns
Transform the given data.
Transform the given data .
def transform(self, c):
        """
        Transform the given data.

        Args:
            c (np.array): an array of type that can be cast to dtype `str`

        Returns:
            np.array of floats representing indices of matched patterns
        """
        nans = np.equal(c, None)
        c = c.astype(str)
        c[nans] = ""
        res = map_by_substring(
            c, self.patterns, self.case_sensitive, self.match_beginning,
            self.map_values)
        res[nans] = np.nan
        return res
def transform ( self , c ) : nans = np . equal ( c , None ) c = c . astype ( str ) c [ nans ] = "" res = map_by_substring ( c , self . patterns , self . case_sensitive , self . match_beginning , self . map_values ) res [ nans ] = np . nan return res