def stem(self, word):
<EOL>word = normalize('<STR_LIT>', text_type(word.lower()))<EOL>word = word.translate(self._accented)<EOL>for i in range(len(word)):<EOL><INDENT>if i == <NUM_LIT:0> and word[<NUM_LIT:0>] == '<STR_LIT:y>':<EOL><INDENT>word = '<STR_LIT:Y>' + word[<NUM_LIT:1>:]<EOL><DEDENT>elif word[i] == '<STR_LIT:y>' and word[i - <NUM_LIT:1>] in self._vowels:<EOL><INDENT>word = word[:i] + '<STR_LIT:Y>' + word[i + <NUM_LIT:1> :]<EOL><DEDENT>elif (<EOL>word[i] == '<STR_LIT:i>'<EOL>and word[i - <NUM_LIT:1>] in self._vowels<EOL>and i + <NUM_LIT:1> < len(word)<EOL>and word[i + <NUM_LIT:1>] in self._vowels<EOL>):<EOL><INDENT>word = word[:i] + '<STR_LIT:I>' + word[i + <NUM_LIT:1> :]<EOL><DEDENT><DEDENT>r1_start = max(<NUM_LIT:3>, self._sb_r1(word))<EOL>r2_start = self._sb_r2(word)<EOL>if word[-<NUM_LIT:5>:] == '<STR_LIT>':<EOL><INDENT>if len(word[r1_start:]) >= <NUM_LIT:5>:<EOL><INDENT>word = word[:-<NUM_LIT:3>] + '<STR_LIT:id>'<EOL><DEDENT><DEDENT>elif word[-<NUM_LIT:3>:] == '<STR_LIT>':<EOL><INDENT>if len(word[r1_start:]) >= <NUM_LIT:3> and (<EOL>word[-<NUM_LIT:4>] not in self._vowels and word[-<NUM_LIT:6>:-<NUM_LIT:3>] != '<STR_LIT>'<EOL>):<EOL><INDENT>word = self._undouble(word[:-<NUM_LIT:3>])<EOL><DEDENT><DEDENT>elif word[-<NUM_LIT:2>:] == '<STR_LIT>':<EOL><INDENT>if len(word[r1_start:]) >= <NUM_LIT:2> and (<EOL>word[-<NUM_LIT:3>] not in self._vowels and word[-<NUM_LIT:5>:-<NUM_LIT:2>] != '<STR_LIT>'<EOL>):<EOL><INDENT>word = self._undouble(word[:-<NUM_LIT:2>])<EOL><DEDENT><DEDENT>elif word[-<NUM_LIT:2>:] == '<STR_LIT>':<EOL><INDENT>if (<EOL>len(word[r1_start:]) >= <NUM_LIT:2><EOL>and word[-<NUM_LIT:3>] not in self._not_s_endings<EOL>):<EOL><INDENT>word = word[:-<NUM_LIT:2>]<EOL><DEDENT><DEDENT>elif word[-<NUM_LIT:1>:] == '<STR_LIT:s>':<EOL><INDENT>if (<EOL>len(word[r1_start:]) >= <NUM_LIT:1><EOL>and word[-<NUM_LIT:2>] not in self._not_s_endings<EOL>):<EOL><INDENT>word = word[:-<NUM_LIT:1>]<EOL><DEDENT><DEDENT>e_removed = False<EOL>if word[-<NUM_LIT:1>:] == '<STR_LIT:e>':<EOL><INDENT>if len(word[r1_start:]) >= <NUM_LIT:1> and word[-<NUM_LIT:2>] not in self._vowels:<EOL><INDENT>word = self._undouble(word[:-<NUM_LIT:1>])<EOL>e_removed = True<EOL><DEDENT><DEDENT>if word[-<NUM_LIT:4>:] == '<STR_LIT>':<EOL><INDENT>if len(word[r2_start:]) >= <NUM_LIT:4> and word[-<NUM_LIT:5>] != '<STR_LIT:c>':<EOL><INDENT>word = word[:-<NUM_LIT:4>]<EOL>if word[-<NUM_LIT:2>:] == '<STR_LIT>':<EOL><INDENT>if len(word[r1_start:]) >= <NUM_LIT:2> and (<EOL>word[-<NUM_LIT:3>] not in self._vowels and word[-<NUM_LIT:5>:-<NUM_LIT:2>] != '<STR_LIT>'<EOL>):<EOL><INDENT>word = self._undouble(word[:-<NUM_LIT:2>])<EOL><DEDENT><DEDENT><DEDENT><DEDENT>if word[-<NUM_LIT:4>:] == '<STR_LIT>':<EOL><INDENT>if len(word[r2_start:]) >= <NUM_LIT:4>:<EOL><INDENT>word = word[:-<NUM_LIT:4>]<EOL>if word[-<NUM_LIT:1>:] == '<STR_LIT:e>':<EOL><INDENT>if (<EOL>len(word[r1_start:]) >= <NUM_LIT:1><EOL>and word[-<NUM_LIT:2>] not in self._vowels<EOL>):<EOL><INDENT>word = self._undouble(word[:-<NUM_LIT:1>])<EOL><DEDENT><DEDENT><DEDENT><DEDENT>elif word[-<NUM_LIT:4>:] == '<STR_LIT>':<EOL><INDENT>if len(word[r2_start:]) >= <NUM_LIT:4>:<EOL><INDENT>word = word[:-<NUM_LIT:4>]<EOL><DEDENT><DEDENT>elif word[-<NUM_LIT:3>:] in ('<STR_LIT:end>', '<STR_LIT>'):<EOL><INDENT>if len(word[r2_start:]) >= <NUM_LIT:3>:<EOL><INDENT>word = word[:-<NUM_LIT:3>]<EOL>if (<EOL>word[-<NUM_LIT:2>:] == '<STR_LIT>'<EOL>and len(word[r2_start:]) >= <NUM_LIT:2><EOL>and word[-<NUM_LIT:3>] != '<STR_LIT:e>'<EOL>):<EOL><INDENT>word = word[:-<NUM_LIT:2>]<EOL><DEDENT>else:<EOL><INDENT>word = self._undouble(word)<EOL><DEDENT><DEDENT><DEDENT>elif word[-<NUM_LIT:3>:] == '<STR_LIT:bar>':<EOL><INDENT>if len(word[r2_start:]) >= <NUM_LIT:3> and e_removed:<EOL><INDENT>word = word[:-<NUM_LIT:3>]<EOL><DEDENT><DEDENT>elif word[-<NUM_LIT:2>:] == '<STR_LIT>':<EOL><INDENT>if len(word[r2_start:]) >= <NUM_LIT:2> and word[-<NUM_LIT:3>] != '<STR_LIT:e>':<EOL><INDENT>word = word[:-<NUM_LIT:2>]<EOL><DEDENT><DEDENT>if (<EOL>len(word) >= <NUM_LIT:4><EOL>and word[-<NUM_LIT:3>] == word[-<NUM_LIT:2>]<EOL>and word[-<NUM_LIT:2>] in {'<STR_LIT:a>', '<STR_LIT:e>', '<STR_LIT:o>', '<STR_LIT:u>'}<EOL>and word[-<NUM_LIT:4>] not in self._vowels<EOL>and word[-<NUM_LIT:1>] not in self._vowels<EOL>and word[-<NUM_LIT:1>] != '<STR_LIT:I>'<EOL>):<EOL><INDENT>word = word[:-<NUM_LIT:2>] + word[-<NUM_LIT:1>]<EOL><DEDENT>for i in range(<NUM_LIT:0>, len(word)):<EOL><INDENT>if word[i] == '<STR_LIT:Y>':<EOL><INDENT>word = word[:i] + '<STR_LIT:y>' + word[i + <NUM_LIT:1> :]<EOL><DEDENT>elif word[i] == '<STR_LIT:I>':<EOL><INDENT>word = word[:i] + '<STR_LIT:i>' + word[i + <NUM_LIT:1> :]<EOL><DEDENT><DEDENT>return word<EOL>
Return Snowball Dutch stem.

        Parameters
        ----------
        word : str
            The word to stem

        Returns
        -------
        str
            Word stem

        Examples
        --------
        >>> stmr = SnowballDutch()
        >>> stmr.stem('lezen')
        'lez'
        >>> stmr.stem('opschorting')
        'opschort'
        >>> stmr.stem('ongrijpbaarheid')
        'ongrijp'