How to use the prophet.analyze.Analysis function in prophet

To help you get started, we’ve selected a few prophet examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Emsu / prophet / prophet / app.py View on Github external
def analyze_backtest(self, backtest):
        """ Analyzes a backtest with the registered portfolio analyzers.

        Args:
            backtest (prophet.backtest.BackTest): a backtest object

        Return:
            prophet.backtest.BackTest
        """
        data = Analysis()
        for analyzer in self._backtest_analyzers:
            data[analyzer.name] = analyzer.run(backtest=backtest,
                                               config=self.config,
                                               data=data)
        return data