class_docstr: Rank1D computes a score for each feature in the data set with a specific
  metric or algorithm (e.g. Shapiro-Wilk) then returns the features ranked
  as a bar plot.
  
  Parameters
  ----------
  algorithm : one of {'shapiro', }, default: 'shapiro'
      The ranking algorithm to use, default is 'Shapiro-Wilk.
  
  features : list
      A list of feature names to use.
      If a DataFrame is passed features is None, feature
      names are selected as the columns of the DataFrame.
  
  figsize : tuple, optional
          (width, height) for specifying the size of the plot.
  
  orient : 'h' or 'v', default='h'
      Specifies a horizontal or vertical bar chart.
  
  color: string
      Specify color for barchart
  
  ax : matplotlib Axes, default: None
      The axis to plot the figure on. If None is passed in the current axes
      will be used (or generated if required).
  
  Attributes
  ----------
  ranks_ : ndarray
      An array of rank scores with shape (n,), where n is the
      number of features.
  
  Examples
  ---------
  .. plot:: ../examples/feature_ranking_1D.py
  
  Notes
  -----
  .. versionadded:: 0.8.4
class_docstr_tok: ["Rank1D","computes","a","score","for","each","feature","in","the","data","set","with","a","specific","metric","or","algorithm","(","e.g",".","Shapiro-Wilk",")","then","returns","the","features","ranked","as","a","bar","plot",".","Parameters","--","--","--","--","--","algorithm",":","one","of","{","'shapiro","'",",","}",",","default",":","'shapiro'","The","ranking","algorithm","to","use",",","default","is","'Shapiro-Wilk",".","features",":","list","A","list","of","feature","names","to","use",".","If","a","DataFrame","is","passed","features","is","None",",","feature","names","are","selected","as","the","columns","of","the","DataFrame",".","figsize",":","tuple",",","optional","(","width",",","height",")","for","specifying","the","size","of","the","plot",".","orient",":","'","h","'","or","'","v","'",",","default=","'","h'","Specifies","a","horizontal","or","vertical","bar","chart",".","color",":","string","Specify","color","for","barchart","ax",":","matplotlib","Axes",",","default",":","None","The","axis","to","plot","the","figure","on",".","If","None","is","passed","in","the","current","axes","will","be","used","(","or","generated","if","required",")",".","Attributes","--","--","--","--","--","ranks_",":","ndarray","An","array","of","rank","scores","with","shape","(","n",",",")",",","where","n","is","the","number","of","features",".","Examples","--","--","--","--","-","..","plot",":",":","..","\/examples\/feature_ranking_1D.py","Notes","--","--","-","..","versionadded",":",":","0.8.4"]
docstr: Draws the bar plot of the ranking array of features.
docstr_tok: ["Draws","the","bar","plot","of","the","ranking","array","of","features","."]
code: def _draw(self):
      """
      Draws the bar plot of the ranking array of features.
      """
  
      title = "{} Ranking of {} Features".format(
          self.algorithm.title(), len(self.features_)
      )
      self.ax.set_title(title)
      if self.orientation_ == "h":
          # Make the plot
          self.ax.barh(
              np.arange(len(self.ranks_)), self.ranks_, color=self.color
          )
  
          # Add ticks and tick labels
          self.ax.set_yticks(np.arange(len(self.ranks_)))
          self.ax.set_yticklabels(self.features_)
          # Order the features from top to bottom on the y axis
          self.ax.invert_yaxis()
          # Turn off y grid lines
          self.ax.set_axisbelow(True)
          self.ax.xaxis.grid(True, color="#808080")
  
      elif self.orientation_ == "v":
          # Make the plot
          self.ax.bar(
              np.arange(len(self.ranks_)), self.ranks_, color=self.color
          )
  
          # Add ticks and tick labels
          self.ax.set_xticks(np.arange(len(self.ranks_)))
          self.ax.set_xticklabels(self.features_, rotation=90)
  
          # Turn off x grid lines
          self.ax.set_axisbelow(True)
          self.ax.yaxis.grid(True, color="#808080")
  
      else:
          raise ValueError("Orientation must be 'h' or 'v'")
      return self.ax
  
imports: import numpy
  import pandas
  from scipy.stats import shapiro
  from scipy.stats import spearmanr
  from scipy.stats import kendalltau
  from sklearn_evaluation.telemetry import SKLearnEvaluationLogger
  from ploomber_core.exceptions import modify_exceptions
  import matplotlib.pyplot
label_desc: Use image node_id 3 for calling the Rank1D obj's underlying member method code with example usage: obj._draw() and returns: self