code_attribute/code_volumn_manager.py
@@ -79,6 +79,18 @@ def get_max_volume_in_5days(self, code): return self.__max_volume_in_5days.get(code) def get_volume_rate_refer_in_5days(self, code): """ 获取今日量与5日最大量的参考值 @param code: @return: """ max_volume = self.get_max_volume_in_5days(code) if not max_volume: return 0 today_volume = self.get_today_volumn(code) return round(today_volume / max_volume, 2) # 获取历史量 def get_histry_volumn(self, code): max60 = global_util.max60_volumn.get(code)