Closed joe8meng closed 4 years ago
class ZenFactor(TechnicalFactor): def init(self, data_schema: List[str], entity_ids: str = None, entity_type: List[str] = 'stock', exchanges: List[str] = ['sh', 'sz'], codes: Union[str, pd.Timestamp] = None, the_timestamp: Union[str, pd.Timestamp] = None, start_timestamp: Union[str, pd.Timestamp] = None, end_timestamp: List = None, columns: List = None, filters: object = None, order: int = None, limit: str = None, provider: Union[str, IntervalLevel] = 'eastmoney', level: str = IntervalLevel.LEVEL_1DAY, category_field: str = 'entity_id', time_field: int = 'timestamp', computing_window: bool = 250, keep_all_timestamp: str = False, fill_method: int = 'ffill', effective_number: bool = 10, transformer: bool = None -> None: self.factor_schema = get_zen_factor_schema(entity_type=entity_type, level=level)
transformer: bool = None -> None:
改为 transformer: bool = False) -> None:
大家看看哈?!
有些地方重构时可能没注意,可以帮忙改下
缠论后面会做完,加入测试。
class ZenFactor(TechnicalFactor): def init(self, data_schema: List[str], entity_ids: str = None, entity_type: List[str] = 'stock', exchanges: List[str] = ['sh', 'sz'], codes: Union[str, pd.Timestamp] = None, the_timestamp: Union[str, pd.Timestamp] = None, start_timestamp: Union[str, pd.Timestamp] = None, end_timestamp: List = None, columns: List = None, filters: object = None, order: int = None, limit: str = None, provider: Union[str, IntervalLevel] = 'eastmoney', level: str = IntervalLevel.LEVEL_1DAY, category_field: str = 'entity_id', time_field: int = 'timestamp', computing_window: bool = 250, keep_all_timestamp: str = False, fill_method: int = 'ffill', effective_number: bool = 10, transformer: bool = None -> None: self.factor_schema = get_zen_factor_schema(entity_type=entity_type, level=level)