stereo.plots.PlotElbow.elbow#

PlotElbow.elbow(pca_res_key='pca', n_pcs=None, width=None, height=None, title='Elbow Plot', x_label='Principal Component', y_label='Variance Explained', line_width=2, color='blue', marker='o', marker_color=None, marker_size=4, cum=False)[source]#

Plot elbow for pca.

Parameters:
  • pca_res_key (str) – the key sepcifies the pca result, defaults to ‘pca’.

  • n_pcs (Optional[int]) – number of PCs to be displayed, defaults to None to show all PCs.

  • width (Optional[int]) – the figure width in pixels, defaults to None.

  • height (Optional[int]) – the figure height in pixels, defaults to None. if width or height is None, they will be set to default value by matplotlib, width defaults to 6.4 inches and height defaults to 4.8 inches.

  • title (str) – the tilte of the plot, defaults to ‘Elbow Plot’.

  • x_label (str) – the label of the x-axis, defaults to ‘Principal Component’.

  • y_label (str) – the label of the y-axis, defaults to ‘Variance Explained’.

  • line_width (int) – the width of the line in plot, defaults to 2.

  • color (str) – the color of the line in plot, defaults to ‘blue’.

  • marker (str) – the marker style, defaults to ‘o’.

  • marker_color (Optional[str]) – the marker color, defaults to the same as line’s color.

  • marker_size (int) – the marker size, defaults to 4.

  • cum (bool) – setting to True means each marker represents a cumulation of current marker and all previous, default to False.