From 4ee5d79b3b048371bc5db1aa41377bee2c0be4ad Mon Sep 17 00:00:00 2001 From: zengbin93 Date: Mon, 28 Sep 2020 15:56:53 +0800 Subject: [PATCH] 0.5.6 update --- czsc/cobra/utils.py | 1 + czsc/plot.py | 5 ++--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/czsc/cobra/utils.py b/czsc/cobra/utils.py index dd0cd3b..6ca727a 100644 --- a/czsc/cobra/utils.py +++ b/czsc/cobra/utils.py @@ -61,6 +61,7 @@ def kdj_gold_cross(kline: Union[List[dict], pd.DataFrame], just: bool = True): traceback.print_exc() return False + def kdj_dead_cross(kline: Union[List[dict], pd.DataFrame], just: bool = True): """输入K线,判断KDJ是否死叉 diff --git a/czsc/plot.py b/czsc/plot.py index 506b3f0..a76f11c 100644 --- a/czsc/plot.py +++ b/czsc/plot.py @@ -4,11 +4,10 @@ """ -from pyecharts.options import HeatMapItem from pyecharts import options as opts from pyecharts.charts import HeatMap, Kline, Line, Bar, Scatter, Grid from pyecharts.commons.utils import JsCode -from typing import List, Callable +from typing import List def heat_map(data: List[dict], @@ -33,7 +32,7 @@ def heat_map(data: List[dict], :return: 图表 """ - value = [HeatMapItem(value=[s['x'], s['y'], s['heat']]) for s in data] + value = [opts.HeatMapItem(value=[s['x'], s['y'], s['heat']]) for s in data] heat = [s['heat'] for s in data] if not x_label: -- GitLab