class_docstr: Parts of speech (e.g. verbs, nouns, prepositions, adjectives)
  indicate how a word is functioning within the context of a sentence.
  In English as in many other languages, a single word can function in
  multiple ways. Part-of-speech tagging lets us encode information not
  only about a word’s definition, but also its use in context (for
  example the words “ship” and “shop” can be either a verb or a noun,
  depending on the context).
  
  The PosTagVisualizer creates a bar chart to visualize the relative
  proportions of different parts-of-speech in a corpus.
  
  Note that the PosTagVisualizer requires documents to already be
  part-of-speech tagged; the visualizer expects the corpus to come in
  the form of a list of (document) lists of (sentence) lists of
  (tag, token) tuples.
  
  Parameters
  ----------
  ax : matplotlib axes
      The axes to plot the figure on.
  
  tagset: string
      The tagset that was used to perform part-of-speech tagging.
      Either "penn_treebank" or "universal", defaults to "penn_treebank".
      Use "universal" if corpus has been tagged using SpaCy.
  
  colors : list or tuple of strings
      Specify the colors for each individual part-of-speech. Will override
      colormap if both are provided.
  
  colormap : string or matplotlib cmap
      Specify a colormap to color the parts-of-speech.
  
  frequency: bool {True, False}, default: False
      If set to True, part-of-speech tags will be plotted according to frequency,
      from most to least frequent.
  
  stack : bool {True, False}, default : False
      Plot the PosTag frequency chart as a per-class stacked bar chart.
      Note that fit() requires y for this visualization.
  
  parser : string or None, default: None
      If set to a string, string must be in the form of 'parser_tagger' or 'parser'
      to use defaults (for spacy this is 'en_core_web_sm', for nltk this is 'word').
      The 'parser' argument is one of the accepted parsing libraries. Currently
      'nltk' and 'spacy' are the only accepted libraries. NLTK or SpaCy must be
      installed into your environment. 'tagger' is the tagset to use. For example
      'nltk_wordpunct' would use the NLTK library with 'wordpunct' tagset. Or
      'spacy_en_core_web_sm' would use SpaCy with the 'en_core_web_sm' tagset.
  
  kwargs : dict
      Pass any additional keyword arguments to the PosTagVisualizer.
  
  Attributes
  ----------
  pos_tag_counts_: dict
      Mapping of part-of-speech tags to counts.
  
  Examples
  --------
  >>> viz = PosTagVisualizer()
  >>> viz.fit(X)
  >>> viz.show()
docstr: Finalize the plot with ticks, labels, and title
  
  Parameters
  ----------
  kwargs: dict
      generic keyword arguments.
docstr_tok: ["Finalize","the","plot","with","ticks",",","labels",",","and","title","Parameters","--","--","--","--","--","kwargs",":","dict","generic","keyword","arguments","."]
code: def finalize(self, **kwargs):
      """
      Finalize the plot with ticks, labels, and title
  
      Parameters
      ----------
      kwargs: dict
          generic keyword arguments.
      """
      # NOTE: not deduping here, so this is total, not unique
      self.ax.set_ylabel("Count")
  
      if self.frequency:
          self.ax.set_xlabel(
              "{} part-of-speech tags, sorted by frequency".format(
                  self.tagset_names[self.tagset]
              )
          )
      else:
          self.ax.set_xlabel(
              "{} part-of-speech tags".format(
                  self.tagset_names[self.tagset]
              )
          )
  
      # bar stack(helper) sets the ticks if stack is true
      if not self.stack:
          self.ax.set_xticks(range(len(self._pos_tags)))
          self.ax.set_xticklabels(self._pos_tags, rotation=90)
  
      self.set_title(
          "PosTag plot for {}-token corpus".format(
              (
                  sum(
                      [
                          sum(i.values())
                          for i in self.pos_tag_counts_.values()
                      ]
                  )
              )
          )
      )
  
      # Call tight layout to maximize readability
      self.fig.tight_layout()
  
imports: import numpy
  import importlib
  from yellowbrick.draw import bar_stack
  from yellowbrick.text.base import TextVisualizer
  from yellowbrick.style.colors import resolve_colors
  from yellowbrick.exceptions import YellowbrickValueError
label_desc: Use image node_id 13 for calling the PosTagVisualizer obj's underlying member method code with example usage: obj.finalize() without return types