Beispiel #1
0
 def make_execution_plan(self, terms):
     return ExecutionPlan(
         terms,
         self.nyse_sessions,
         self.execution_plan_start,
         self.execution_plan_end,
     )
Beispiel #2
0
 def make_execution_plan(self, terms):
     return ExecutionPlan(
         domain=self.DOMAIN,
         terms=terms,
         start_date=self.execution_plan_start,
         end_date=self.execution_plan_end,
     )
Beispiel #3
0
    def run_terms(self, terms, initial_workspace, mask):
        start_date, end_date = mask.index[[0, -1]]
        graph = ExecutionPlan(
            domain=US_EQUITIES,
            terms=terms,
            start_date=start_date,
            end_date=end_date,
        )

        return self.run_graph(graph, initial_workspace, mask)
Beispiel #4
0
    def check_terms(self,
                    terms,
                    expected,
                    initial_workspace,
                    mask,
                    check=check_arrays):
        """
        Compile the given terms into a TermGraph, compute it with
        initial_workspace, and compare the results with ``expected``.
        """
        start_date, end_date = mask.index[[0, -1]]
        graph = ExecutionPlan(
            domain=US_EQUITIES,
            terms=terms,
            start_date=start_date,
            end_date=end_date,
        )

        results = self.run_graph(graph, initial_workspace, mask)
        for key, (res, exp) in dzip_exact(results, expected).items():
            check(res, exp)

        return results