股票K线图与MACD指标横轴同步缩放显示,MACD显示DIFF、DEA和柱状图,方便同步查看股票价格与MACD指标之间的关系,在使用代码辅助分析时,通过该控件可以方便所得分析结果可见,协助分析。

目录

效果

代码

使用

数据


效果

代码

导入需要的包、单K控件、日期横轴控件、线段柱状图控件、日期计算方法

import sys,json
import numpy as np
from datetime import datetime
from dateutil.relativedelta import relativedelta
from typing import Dict,Any
from PyQt5 import QtCore,QtGui,QtWidgets
from PyQt5.QtCore import Qt
import pyqtgraph as pg
import pyqtgraph.examples
pg.setConfigOption('background','k')
pg.setConfigOption('foreground','w')# 返回今天的日期
def res_date_normal_str():return datetime.now().strftime('%Y-%m-%d')
# 返回今年第一天
def res_current_year_first_day():now_day = datetime.today()current_year = now_day.yearres_str = f"{current_year}-01-01"return res_strpass
# 往回推一年的第一天
def res_pre_year_first_day():# https://blog.csdn.net/weixin_42185136/article/details/108646120pre_year_day = (datetime.now()-relativedelta(years=1)).strftime('%Y-%m-%d')return pre_year_day
# 往回推两年的第一天
def res_pre_two_year_first_day():pre_year_day = (datetime.now() - relativedelta(years=2)).strftime('%Y-%m-%d')return pre_year_dayclass RotateAxisItem(pg.AxisItem):def drawPicture(self, p, axisSpec, tickSpecs, textSpecs):p.setRenderHint(p.Antialiasing,False)p.setRenderHint(p.TextAntialiasing,True)## draw long line along axispen,p1,p2 = axisSpecp.setPen(pen)p.drawLine(p1,p2)p.translate(0.5,0)  ## resolves some damn pixel ambiguity## draw ticksfor pen,p1,p2 in tickSpecs:p.setPen(pen)p.drawLine(p1,p2)## draw all text# if self.tickFont is not None:#     p.setFont(self.tickFont)p.setPen(self.pen())for rect,flags,text in textSpecs:# this is the important partp.save()p.translate(rect.x(),rect.y())p.rotate(-30)p.drawText(-rect.width(),rect.height(),rect.width(),rect.height(),flags,text)# restoring the painter is *required*!!!p.restore()class CandlestickItem(pg.GraphicsObject):def __init__(self, data):pg.GraphicsObject.__init__(self)self.data = data  ## data must have fields: time, open, close, min, maxself.generatePicture()def generatePicture(self):## pre-computing a QPicture object allows paint() to run much more quickly,## rather than re-drawing the shapes every time.self.picture = QtGui.QPicture()p = QtGui.QPainter(self.picture)p.setPen(pg.mkPen('d'))w = (self.data[1][0] - self.data[0][0]) / 3.for (t, open, close, min, max) in self.data:p.drawLine(QtCore.QPointF(t, min), QtCore.QPointF(t, max))if open > close:p.setBrush(pg.mkBrush('r'))else:p.setBrush(pg.mkBrush('g'))p.drawRect(QtCore.QRectF(t - w, open, w * 2, close - open))p.end()def paint(self, p, *args):p.drawPicture(0, 0, self.picture)def boundingRect(self):## boundingRect _must_ indicate the entire area that will be drawn on## or else we will get artifacts and possibly crashing.## (in this case, QPicture does all the work of computing the bouning rect for us)return QtCore.QRectF(self.picture.boundingRect())class SegmenttickItem(pg.GraphicsObject):def __init__(self, data):pg.GraphicsObject.__init__(self)self.data = data  ## data must have fields: time, valueself.generatePicture()def generatePicture(self):self.picture = QtGui.QPicture()p = QtGui.QPainter(self.picture)for (t,val) in self.data:if val > 0.0:p.setPen(pg.mkPen('r'))p.drawLine(QtCore.QPointF(t,0), QtCore.QPointF(t,val))else:p.setPen(pg.mkPen('g'))p.drawLine(QtCore.QPointF(t, 0), QtCore.QPointF(t, val))p.end()def paint(self, p, *args):p.drawPicture(0, 0, self.picture)def boundingRect(self):return QtCore.QRectF(self.picture.boundingRect())

K线和指标同步显示控件

class PyQtGraphLineWidget(QtWidgets.QWidget):def __init__(self):super().__init__()self.init_data()self.init_ui()passdef init_data(self):self.please_select_str = '---请选择---'self.func_map = {}self.func_item_list = []self.duration_map = {'今年':'a','最近一年':'b','最近两年':'c'}# https://www.sioe.cn/yingyong/yanse-rgb-16/self.color_line = (30, 144, 255)self.color_ma_5 = (248,248,255) # 幽灵的白色self.color_ma_10 = (255,255,0) # 纯黄self.color_ma_20 = (255,0,255) # 紫红色self.color_ma_30 = (0,128,0) # 纯绿self.color_ma_60 = (30,144,255) # 道奇蓝self.color_up = (220,20,60)self.color_down = (60,179,113)self.main_fixed_target_list = []  # 主体固定曲线,不能被删除self.whole_df = Noneself.whole_header = Noneself.whole_header2 = Noneself.whole_pd_header = Noneself.whole_pd_header2 = Noneself.current_whole_data = Noneself.current_whole_data2 = Noneself.current_whole_df = Nonepassdef init_ui(self):# 控制面板 startleft_tip = QtWidgets.QLabel('左边界')self.left_point = QtWidgets.QDateEdit()self.left_point.setDisplayFormat('yyyy-MM-dd')self.left_point.setCalendarPopup(True)right_tip = QtWidgets.QLabel('右边界')self.right_point = QtWidgets.QDateEdit()self.right_point.setDisplayFormat('yyyy-MM-dd')self.right_point.setCalendarPopup(True)duration_sel_btn = QtWidgets.QPushButton('确定')duration_sel_btn.clicked.connect(self.duration_sel_btn_clicked)duration_reset_btn = QtWidgets.QPushButton('重置')duration_reset_btn.clicked.connect(self.duration_reset_btn_clicked)duration_tip = QtWidgets.QLabel('常用时间')self.duration_combox = QtWidgets.QComboBox()self.duration_combox.addItem(self.please_select_str)self.duration_combox.addItems(list(self.duration_map.keys()))self.duration_combox.currentIndexChanged.connect(self.duration_combox_currentIndexChanged)combox_tip = QtWidgets.QLabel('功能')self.func_combox = QtWidgets.QComboBox()self.func_combox.addItem(self.please_select_str)self.func_combox.addItems(list(self.func_map.keys()))self.func_combox.currentIndexChanged.connect(self.func_combox_currentIndexChanged)clear_func_btn = QtWidgets.QPushButton('清空功能区')clear_func_btn.clicked.connect(self.clear_func_btn_clicked)self.whole_duration_label = QtWidgets.QLabel('原始最宽边界:左边界~右边界')self.now_duration_label = QtWidgets.QLabel('当前显示最宽边界:左边界~右边界')layout_date = QtWidgets.QHBoxLayout()layout_date.addWidget(left_tip)layout_date.addWidget(self.left_point)layout_date.addWidget(right_tip)layout_date.addWidget(self.right_point)layout_date.addWidget(duration_sel_btn)layout_date.addWidget(duration_reset_btn)layout_date.addSpacing(30)layout_date.addWidget(duration_tip)layout_date.addWidget(self.duration_combox)layout_date.addSpacing(30)layout_date.addWidget(combox_tip)layout_date.addWidget(self.func_combox)layout_date.addWidget(clear_func_btn)layout_date.addStretch(1)layout_duration = QtWidgets.QHBoxLayout()layout_duration.addWidget(self.whole_duration_label)layout_duration.addSpacing(30)layout_duration.addWidget(self.now_duration_label)layout_duration.addStretch(1)# 控制面板 endself.title_label = QtWidgets.QLabel('均线训练')self.title_label.setAlignment(Qt.AlignCenter)self.title_label.setStyleSheet('QLabel{font-size:18px;font-weight:bold}')xax = RotateAxisItem(orientation='bottom')xax.setHeight(h=60)xax2 = RotateAxisItem(orientation='bottom')xax2.setHeight(h=60)self.pw = pg.PlotWidget(axisItems={'bottom': xax})self.pw2 = pg.PlotWidget(axisItems={'bottom': xax2})# self.pw.setMouseEnabled(x=True, y=True)# self.pw.enableAutoRange(x=False,y=True)# self.pw.setAutoVisible(x=False, y=True)layout_pw = QtWidgets.QVBoxLayout()layout_pw.addWidget(self.pw,2)layout_pw.addWidget(self.pw2,1)layout = QtWidgets.QVBoxLayout()layout.addWidget(self.title_label)layout.addLayout(layout_date)layout.addLayout(layout_duration)layout.addLayout(layout_pw)self.setLayout(layout)passdef set_data(self,data:Dict[str,Any]):title_str = data['title_str']whole_header = data['whole_header']whole_header2 = data['whole_header2']whole_df = data['whole_df']whole_pd_header = data['whole_pd_header']whole_pd_header2 = data['whole_pd_header2']self.whole_header = whole_headerself.whole_header2 = whole_header2self.whole_df = whole_dfself.whole_pd_header = whole_pd_headerself.whole_pd_header2 = whole_pd_header2self.title_label.setText(title_str)self.whole_duration_label.setText(f"原始最宽边界:{self.whole_df.iloc[0]['tradeDate']}~{self.whole_df.iloc[-1]['tradeDate']}")self.current_whole_df = self.whole_df.copy()self.caculate_and_show_data()passdef caculate_and_show_data(self):df = self.current_whole_df.copy()df.reset_index(inplace=True)tradeDate_list = df['tradeDate'].values.tolist()x = range(len(df))xTick_show = []x_dur = math.ceil(len(df)/20)for i in range(0,len(df),x_dur):xTick_show.append((i,tradeDate_list[i]))if len(df)%20 != 0:xTick_show.append((len(df)-1,tradeDate_list[-1]))candle_data = []segment_data = []for i,row in df.iterrows():candle_data.append((i,row['openPrice'],row['closePrice'],row['lowestPrice'],row['highestPrice']))segment_data.append((i,row['MACD']))self.current_whole_data = df.loc[:,self.whole_pd_header].values.tolist()self.current_whole_data2 = df.loc[:,self.whole_pd_header2].values.tolist()# 开始配置显示的内容self.pw.clear()self.pw2.clear()self.func_item_list.clear()self.now_duration_label.setText(f"当前显示最宽边界:{df.iloc[0]['tradeDate']}~{df.iloc[-1]['tradeDate']}")xax = self.pw.getAxis('bottom')xax.setTicks([xTick_show])xax2 = self.pw2.getAxis('bottom')xax2.setTicks([xTick_show])candle_fixed_target = CandlestickItem(candle_data)self.main_fixed_target_list.append(candle_fixed_target)self.pw.addItem(candle_fixed_target)# 指标diff_fixed_target = pg.PlotCurveItem(x=np.array(x), y=np.array(df['DIFF'].values.tolist()),pen=pg.mkPen({'color': self.color_ma_5, 'width': 1}),connect='finite')dea_fixed_target = pg.PlotCurveItem(x=np.array(x), y=np.array(df['DEA'].values.tolist()),pen=pg.mkPen({'color': self.color_ma_10, 'width': 1}),connect='finite')segment_fixed_target = SegmenttickItem(segment_data)self.main_fixed_target_list.append(diff_fixed_target)self.main_fixed_target_list.append(dea_fixed_target)self.main_fixed_target_list.append(segment_fixed_target)self.pw2.addItem(segment_fixed_target)self.pw2.addItem(diff_fixed_target)self.pw2.addItem(dea_fixed_target)self.pw2.setXLink(self.pw)self.vLine = pg.InfiniteLine(angle=90, movable=False)self.hLine = pg.InfiniteLine(angle=0, movable=False)self.label = pg.TextItem()self.vLine2 = pg.InfiniteLine(angle=90, movable=False)self.hLine2 = pg.InfiniteLine(angle=0, movable=False)self.label2 = pg.TextItem()self.pw.addItem(self.vLine, ignoreBounds=True)self.pw.addItem(self.hLine, ignoreBounds=True)self.pw.addItem(self.label, ignoreBounds=True)self.pw2.addItem(self.vLine2, ignoreBounds=True)self.pw2.addItem(self.hLine2, ignoreBounds=True)self.pw2.addItem(self.label2, ignoreBounds=True)self.vb = self.pw.getViewBox()self.proxy = pg.SignalProxy(self.pw.scene().sigMouseMoved, rateLimit=60, slot=self.mouseMoved)self.pw.enableAutoRange()self.vb2 = self.pw2.getViewBox()self.proxy2 = pg.SignalProxy(self.pw2.scene().sigMouseMoved, rateLimit=60, slot=self.mouseMoved2)self.pw2.enableAutoRange()passdef mouseMoved(self,evt):pos = evt[0]if self.pw.sceneBoundingRect().contains(pos):mousePoint = self.vb.mapSceneToView(pos)index = int(mousePoint.x())if index>=0 and index<len(self.current_whole_data):target_data = self.current_whole_data[index]html_str = ''for i,item in enumerate(self.whole_header):html_str += f"<br/>{item}:{target_data[i]}"self.label.setHtml(html_str)self.label.setPos(mousePoint.x(),mousePoint.y())self.vLine.setPos(mousePoint.x())self.hLine.setPos(mousePoint.y())self.vLine2.setPos(mousePoint.x())passdef mouseMoved2(self,evt):pos = evt[0]if self.pw2.sceneBoundingRect().contains(pos):mousePoint = self.vb2.mapSceneToView(pos)index = int(mousePoint.x())if index >= 0 and index < len(self.current_whole_data2):target_data = self.current_whole_data2[index]html_str = ''for i, item in enumerate(self.whole_header2):html_str += f"<br/>{item}:{target_data[i]}"self.label2.setHtml(html_str)self.label2.setPos(mousePoint.x(), mousePoint.y())self.vLine2.setPos(mousePoint.x())self.hLine2.setPos(mousePoint.y())self.vLine.setPos(mousePoint.x())passdef mouseClicked(self,evt):passdef updateViews(self):pass# 图形操作之外def duration_sel_btn_clicked(self):'''边界选择'''left_point = self.left_point.date().toString('yyyy-MM-dd')right_point = self.right_point.date().toString('yyyy-MM-dd')df = self.whole_df.copy()df['o_date'] = pd.to_datetime(df['tradeDate'])self.current_whole_df = df.loc[(df['o_date']>=left_point) & (df['o_date']<=right_point)].copy()self.caculate_and_show_data()passdef duration_reset_btn_clicked(self):'''边界重置'''self.current_whole_df = self.whole_df.copy()self.caculate_and_show_data()passdef duration_combox_currentIndexChanged(self,cur_i:int):cur_txt = self.duration_combox.currentText()if cur_txt == self.please_select_str:returncur_code = self.duration_map[cur_txt]right_point = res_date_normal_str()if cur_code == 'a':left_point = res_current_year_first_day()elif cur_code == 'b':left_point = res_pre_year_first_day()elif cur_code == 'c':left_point = res_pre_two_year_first_day()else:returndf = self.whole_df.copy()df['o_date'] = pd.to_datetime(df['tradeDate'])self.current_whole_df = df.loc[(df['o_date'] >= left_point) & (df['o_date'] <= right_point)].copy()self.caculate_and_show_data()passdef func_combox_currentIndexChanged(self,cur_i:int):cur_txt = self.func_combox.currentText()if cur_txt == self.please_select_str:returncur_code = self.func_map[cur_txt]df = self.current_whole_df.copy()if cur_code == 'a':# 多头排列 startdf['count'] = range(len(df))df['duo'] = 0df.loc[(df['ma5'] > df['ma10']) & (df['ma10'] > df['ma20']) & (df['ma20'] > df['ma30']) & (df['ma30'] > df['ma60']), 'duo'] = 1df['ext_0'] = df['duo'] - df['duo'].shift(1)df['ext_1'] = df['duo'] - df['duo'].shift(-1)duo_pre_df = df.loc[df['ext_0'] == 1].copy()duo_fix_df = df.loc[df['ext_1'] == 1].copy()pre_count_list = duo_pre_df['count'].values.tolist()pre_date_list = duo_pre_df['tradeDate'].values.tolist()fix_count_list = duo_fix_df['count'].values.tolist()fix_date_list = duo_fix_df['tradeDate'].values.tolist()if fix_count_list[0]<pre_count_list[0]:fix_count_list = fix_count_list[1:]fix_date_list = fix_date_list[1:]if fix_count_list[-1]<pre_count_list[-1]:pre_count_list = pre_count_list[0:-1]pre_date_list = pre_date_list[0:-1]font = QtGui.QFont()font.setPixelSize(9)for i, item in enumerate(fix_count_list):# 排除掉多头排列三日以下的区间if item-pre_count_list[i] <= 3:continuelr = pg.LinearRegionItem([pre_count_list[i], item],movable=False,brush=(self.color_up[0],self.color_up[1],self.color_up[2],50))lr.setZValue(-100)label_l = pg.InfLineLabel(lr.lines[0],pre_date_list[i],position=0.90,rotateAxis=(1,0),anchor=(1,1),color=self.color_up)label_l.setFont(font)label_r = pg.InfLineLabel(lr.lines[1],fix_date_list[i],position=0.90,rotateAxis=(1,0),anchor=(1,1),color=self.color_up)label_r.setFont(font)self.func_item_list.append(lr)self.pw.addItem(lr)# 多头排列 endpasselif cur_code == 'b':# 空头排列 startdf['count'] = range(len(df))df['duo'] = 0df.loc[(df['ma5'] < df['ma10']) & (df['ma10'] < df['ma20']) & (df['ma20'] < df['ma30']) & (df['ma30'] < df['ma60']), 'duo'] = 1df['ext_0'] = df['duo'] - df['duo'].shift(1)df['ext_1'] = df['duo'] - df['duo'].shift(-1)duo_pre_df = df.loc[df['ext_0'] == 1].copy()duo_fix_df = df.loc[df['ext_1'] == 1].copy()pre_count_list = duo_pre_df['count'].values.tolist()pre_date_list = duo_pre_df['tradeDate'].values.tolist()fix_count_list = duo_fix_df['count'].values.tolist()fix_date_list = duo_fix_df['tradeDate'].values.tolist()if fix_count_list[0] < pre_count_list[0]:fix_count_list = fix_count_list[1:]fix_date_list = fix_date_list[1:]if fix_count_list[-1] < pre_count_list[-1]:pre_count_list = pre_count_list[0:-1]pre_date_list = pre_date_list[0:-1]font = QtGui.QFont()font.setPixelSize(9)for i, item in enumerate(fix_count_list):# 排除掉空头排列三日以下的区间if item - pre_count_list[i] <= 3:continuelr = pg.LinearRegionItem([pre_count_list[i], item], movable=False, brush=(self.color_down[0],self.color_down[1],self.color_down[2], 50))lr.setZValue(-100)label_l = pg.InfLineLabel(lr.lines[0], pre_date_list[i], position=0.90, rotateAxis=(1, 0),anchor=(1, 1), color=self.color_down)label_l.setFont(font)label_r = pg.InfLineLabel(lr.lines[1], fix_date_list[i], position=0.90, rotateAxis=(1, 0),anchor=(1, 1), color=self.color_down)label_r.setFont(font)self.func_item_list.append(lr)self.pw.addItem(lr)# 空头排列 endpasselif cur_code == 'c':# 20日线斜率为正 startdf['count'] = range(len(df))df['ext_0'] = df['ma20'] - df['ma20'].shift(1)df['ext_1'] = 0df.loc[df['ext_0']>0,'ext_1'] = 1df['ext_2'] = df['ext_1'] - df['ext_1'].shift(1)df['ext_3'] = df['ext_1'] - df['ext_1'].shift(-1)duo_pre_df = df.loc[df['ext_2'] == 1].copy()duo_fix_df = df.loc[df['ext_3'] == 1].copy()pre_count_list = duo_pre_df['count'].values.tolist()pre_date_list = duo_pre_df['tradeDate'].values.tolist()fix_count_list = duo_fix_df['count'].values.tolist()fix_date_list = duo_fix_df['tradeDate'].values.tolist()if fix_count_list[0] < pre_count_list[0]:fix_count_list = fix_count_list[1:]fix_date_list = fix_date_list[1:]if fix_count_list[-1] < pre_count_list[-1]:pre_count_list = pre_count_list[0:-1]pre_date_list = pre_date_list[0:-1]font = QtGui.QFont()font.setPixelSize(9)for i, item in enumerate(fix_count_list):# if item - pre_count_list[i] <= 3:#     continuelr = pg.LinearRegionItem([pre_count_list[i], item], movable=False, brush=(self.color_up[0], self.color_up[1], self.color_up[2], 50))lr.setZValue(-100)label_l = pg.InfLineLabel(lr.lines[0], pre_date_list[i], position=0.90, rotateAxis=(1, 0),anchor=(1, 1), color=self.color_up)label_l.setFont(font)label_r = pg.InfLineLabel(lr.lines[1], fix_date_list[i], position=0.90, rotateAxis=(1, 0),anchor=(1, 1), color=self.color_up)label_r.setFont(font)self.func_item_list.append(lr)self.pw.addItem(lr)# 20日线斜率为正 endpasselif cur_code == 'd':# 阶段最高点最低点 start# 最高点df['ext_0'] = df['closePrice'].cummax()df['ext_1'] = df['ext_0'] - df['ext_0'].shift(1)# 最低点df['ext_2'] = df['closePrice'].cummin()df['ext_3'] = df['ext_2'] - df['ext_2'].shift(1)max_point_df = df.loc[df['ext_1']==0].copy()min_point_df = df.loc[df['ext_3']==0].copy()# 阶段最高点最低点 endpasspassdef clear_func_btn_clicked(self):for item in self.func_item_list:self.pw.removeItem(item)self.func_item_list.clear()passpass

使用

if __name__ == '__main__':# 先显示蜡烛图# 600660  福耀玻璃import pandas as pdimport mathimport talibdf = pd.read_csv('E:/temp005/600660.csv',encoding='utf-8')# 删除停牌的数据df = df.loc[df['openPrice']>0].copy()df['openPrice'] = df['openPrice']*df['accumAdjFactor']df['closePrice'] = df['closePrice']*df['accumAdjFactor']df['highestPrice'] = df['highestPrice']*df['accumAdjFactor']df['lowestPrice'] = df['lowestPrice']*df['accumAdjFactor']# 计算指标close_list = df['closePrice']df['DIFF'],df['DEA'],df['MACD'] = talib.MACD(close_list,fastperiod=12,slowperiod=26,signalperiod=9)whole_pd_header = ['tradeDate','closePrice','openPrice','highestPrice','lowestPrice']whole_pd_header2 = ['tradeDate','DIFF','DEA','MACD']line_data = {'title_str':'福耀玻璃','whole_header':['日期','收盘价','开盘价','最高价','最低价'],'whole_header2':['日期','DIFF','DEA','MACD'],'whole_pd_header':whole_pd_header,'whole_pd_header2':whole_pd_header2,'whole_df':df}app = QtWidgets.QApplication(sys.argv)t_win = PyQtGraphLineWidget()t_win.show()t_win.set_data(line_data)sys.exit(app.exec_())pass

滚动鼠标滑轮,可以实现K线与指标的同步缩放

数据

链接:https://pan.baidu.com/s/1HPkMsDDyXTEgffoAVIhbZw 
提取码:h80x

PyQt5_pyqtgraph股票MACD指标相关推荐

  1. 股票macd指标api接口

    ##股票macd指标api接口 接口url: http://54199.top/ja/public/day_macd_a?id=600590&date=2020-12-02&token ...

  2. 股票MACD指标算法公式

    MACD指标是股票技术中最实用最重要的指标之一,其中涉及EMA.DIF.DEA.BAR几个指标.然而,对MACD指标的定义及分解算法,书上和网上的资料乱七八糟,有的说法互相矛盾,特别是对于指标的分解( ...

  3. python分析股票MACD指标

    股民朋友肯定熟悉股票中的MACD指标,比如5日均线.10日均线.15日均线等等.通过这些指标可以辅助进行交易的决策(比如经典的金叉.死叉理论),下面就以5日均线和20日均线为例,用python来画出指 ...

  4. 国内股票MACD指标计算,Python实现MACD指标计算,Talib实现MACD指标计算

    0 引言 MACD指标是最为常见的指标之一,股票每日的K线数据通过Tushare.Baostock等平台能够获取到个股及指数的Open.High.Low.Close.Volume等数据,MACD等技术 ...

  5. 股票 MACD指标的买入形态图解

    MACD指标中的DIF和DEA两线,按照其金叉时在零轴上.下的位置,和金叉前是否发生过死叉.死叉发生的位置,有八种形态图形.       它们分别是:佛手向上.小鸭出水.漫步青云.天鹅展翅.空中缆绳. ...

  6. PyQt5_pyqtgraph股票SAR指标

    股票K线图与SAR指标横轴同步缩放显示,SAR显示美式K线图和红绿豆,方便同步查看股票价格与SAR指标之间的关系,在使用代码辅助分析时,通过该控件可以方便所得分析结果可见,协助分析. 目录 效果 代码 ...

  7. PyQt5_pyqtgraph股票RSI指标

    股票K线图与RSI指标横轴同步缩放显示,方便同步查看股票价格与RSI指标之间的关系,在使用代码辅助分析时,通过该控件可以方便所得分析结果可见,协助分析. 目录 效果 代码 使用 数据 效果 代码 需要 ...

  8. 股票macd指标java,股票K线指标算法整理(Java封装工具类)

    工具类下载地址: https://download.csdn.net/download/qq_28844947/11088865 可查看应用效果之一:https://www.coinsmt.com/f ...

  9. 修改一个公式让MACD指标更加准确,快速找到股票买点。

    在MACD指标公式编辑器再追加输入一个公式,就可能让MACD显示的更加精准,黄柱开始的地方就是我们要找的股票买点附近. MACD作为"指标之王",深受股民喜爱,使用频率也是非常高. ...

  10. 如何生成股票的macd指标

    查看B站视频 股票技术术语中有很多重要的指标,例如 ma macd kdj rsi 等 接下来, 介绍如何构造 ma 与 macd这两个指标 为避免现金分红带来的影响, 我们以未分红过的新股为例进行演 ...

最新文章

  1. 【JZOJ5064】【GDOI2017第二轮模拟day2】友好城市 Kosarajo算法+bitset+ST表+分块
  2. mac睡眠快捷键_mac键盘快捷键大全
  3. 6、Gerrit插件
  4. sql是否包含多个字符串_工作中遇到的99%SQL优化,这里都能给你解决方案
  5. 拥抱开源!除了微软红帽,这些国际大厂你认识几个?
  6. 第十五章 Python和Web
  7. android如何引用布局,android 动态布局与引用第三方layout中的布局
  8. 快乐数(Leetcode第202题)
  9. linux c语言 udp 接收和发送数据用同一个端口_网络编程基础入门及TCP,UDP
  10. 斗地主AI算法——第十一章の被动出牌(5)
  11. [转载]Qt之自定义界面(二)添加最小化、关闭按钮、添加背景_vortex_新浪博客...
  12. PHP的静态变量和引用函数
  13. 国密SM4对称算法实现说明(原SMS4无线局域网算法标准)
  14. iphone 推送服务--Apple Push Notification Service
  15. WIN10系统重新安装与初始化教程
  16. 人脸识别门禁应用方案
  17. Nios II自学笔记一:Nios II软硬件架构介绍
  18. 华南理工计算机就业棒棒,国内3所校名“一字之差”的大学:均为理工大学,实力却天差地别...
  19. python自动获取某网站二次元图片下载
  20. 使用FFMPEG将WebM转为MP4或MKV

热门文章

  1. java矩形面积_Java编程求矩形的面积
  2. CSDN博客去广告-谷歌插件
  3. 2016年9月学习总结与反思
  4. linux samba 漏洞 exp,smaba漏洞总结
  5. python 将微信聊天记录生成词云
  6. 如何批量将 jpg 图片转换为 png 格式
  7. Win10电脑版微信来消息提醒工具
  8. c语言 白噪声,高斯白噪声 C语言实现
  9. WLAN和WIFI区别以及组网方式
  10. office VBA 学习