COPOD explain_outlier: add option to add feature names to plot
Currently, the generated plot just shows Dimension 1, 2, ...
etc. as the labels on the x-axis. This is not very informative.
It would be nice if you could optionally supply a list of strings to the function, to add labels to the xticks of the plot.
This could look something like this:
def explain_outlier(self, ind, cutoffs=None, feature_names=None): # pragma: no cover
...
if feature_names is not None:
plt.xticks(ticks=range(1, self.O.shape[1] + 1),labels=feature_names)
else:
plt.xticks(ticks=range(1, self.O.shape[1] + 1))
...