WillianFuks / tfcausalimpact

Python Causal Impact Implementation Based on Google's R Package. Built using TensorFlow Probability.
Apache License 2.0
593 stars 70 forks source link

Saving Figures of the Model Output #70

Closed mekazanc closed 1 year ago

mekazanc commented 1 year ago

I want to save original figures but model.plot() returns None so that I could not save them with high quality. Adding such a feature definitely will be helpful.

WillianFuks commented 1 year ago

Hi @mekazanc ,

This package already offers support for that (maybe we should better document this feature still).

To manage your figures, you can run ci.plot(show=False) and then run commands such as:

import matplotlib.pyplot as plt

plt.savefig(...)

This will save your plots as expected (you can also manipulate the axis as you wish as well).

Please let me know if this works for you,

mekazanc commented 1 year ago

Thank you very much @WillianFuks