LSYS/forestplot

Changing the line color indicating statistical significance

juancq opened this issue · 6 comments

Great package!

Where in the code should I look if I want to modify the plotting so that I can change the color of a line when the corresponding row is statistically significant? I don't want to show the p-values or the stars, I just want to change the line color.

LSYS commented

Hi @juancq, thank you for using the package! Do you mean the color of the confidence interval lines? Those would be from the linecolor kwarg

linecolor = kwargs.get("linecolor", ".6")

and
ecolor=linecolor,

But off the top of my mind I'm not sure how easy it would be change colors just for selected rows. I'm using the errorbar API to draw the confidence intervals (https://matplotlib.org/stable/api/_as_gen/matplotlib.axes.Axes.errorbar.html)

I'll play around with the code and see if there's an easy way to implement it.