大伊人青草狠狠久久-大伊香蕉精品视频在线-大伊香蕉精品一区视频在线-大伊香蕉在线精品不卡视频-大伊香蕉在线精品视频75-大伊香蕉在线精品视频人碰人

您現(xiàn)在的位置:程序化交易>> 期貨公式>> 金字塔等>> 其他期貨軟件知識(shí)>>正文內(nèi)容

vbs如何向公式系統(tǒng)傳遞數(shù)組 [金字塔]

  • 咨詢內(nèi)容:

    vbs中有如下類型數(shù)據(jù),如何向金字塔公式系統(tǒng)傳遞?

    dc := 1000;
    VARIABLE:openPrice2[dc]=0;
    <%

    vOpenPrice2 = ffl.vardata("openPrice2")


    '對(duì)vOpenPrice2數(shù)組中每個(gè)元素進(jìn)行計(jì)算處理并賦值

    '......

     

    ffl.vardata("openPrice2") = vOpenPrice2

    %>

     

    請(qǐng)問以上寫法正確嗎?

     

  • 金字塔客服: 測(cè)試一下不就知道了,用MSGBOX打印看看傳遞過去的數(shù)據(jù)是否是數(shù)組

     

  • 用戶回復(fù):

    openPrice := open;
    highPrice := high;
    lowPrice := low;
    closePrice := close;
    dc := 1000;
    VARIABLE:openPrice2[dc]=0,highPrice2[dc]=0,lowPrice2[dc]=0,closePrice2[dc]=0;
    <%
    vOpenPrice = ffl.vardata("openPrice")
    vHighPrice = ffl.vardata("highPrice")
    vLowPrice = ffl.vardata("lowPrice")
    vClosePrice = ffl.vardata("closePrice")
    last = ubound(vOpenPrice)
    vo = 0
    vh = 0
    vl = 0
    vc = 0
    i = 1
    j = 0
    dim openPriceArray(1000)
    dim highPriceArray(1000)
    dim lowPriceArray(1000)
    dim closePriceArray(1000)
    do while(i <= last)
      if ((vOpenPrice(i) > vClosePrice(i)) and (vOpenPrice(i-1) < vClosePrice(i-1))) then '前面一根是陽線,后面連續(xù)陰線 
      vo = vOpenPrice(i)
      vh = vHighPrice(i)
      vl = vLowPrice(i)
      vc = vClosePrice(i) 
      i = i + 1 
      do until ((vOpenPrice(i+1) < vClosePrice(i+1)) or (i > 1000)) '連續(xù)陰線直到遇到陽線為止
        vc = vClosePrice(i)   
        if (vHighPrice(i) > vh) then
          vh = vHighPrice(i)
        end if   
        if (vLowPrice(i) < vl) then
          vl = vLowPrice(i)
        end if   
        i = i + 1 
      loop 
      openPriceArray(j) = vo
      highPriceArray(j) = vh
      lowPriceArray(j) = vl
      closePriceArray(j) = vc 
      j = j + 1       
      end if
      if ((vOpenPrice(i) < vClosePrice(i)) and (vOpenPrice(i-1) > vClosePrice(i-1))) then '前面一根是陰線,后面連續(xù)陽線 
      vo = vOpenPrice(i)
      vh = vHighPrice(i)
      vl = vLowPrice(i)
      vc = vClosePrice(i) 
      i = i + 1 
      do until ((vOpenPrice(i+1) > vClosePrice(i+1)) or (i > 1000)) '連續(xù)陽線直到遇到陰線為止
        vc = vClosePrice(i)   
        if (vHighPrice(i) > vh) then
          vh = vHighPrice(i)
        end if   
        if (vLowPrice(i) < vl) then
          vl = vLowPrice(i)
        end if   
        i = i + 1 
      loop 
      openPriceArray(j) = vo
      highPriceArray(j) = vh
      lowPriceArray(j) = vl
      closePriceArray(j) = vc 
      j = j + 1       
      end if 
    loop
    ffl.vardata("openPrice2") = openPriceArray
    ffl.vardata("highPrice2") = highPriceArray
    ffl.vardata("lowPrice2") = lowPriceArray
    ffl.vardata("closePrice2") = closePriceArray
    %>
    //KLINE(openPrice,highPrice,lowPrice,closePrice,1);
    KLINE(openPrice2,highPrice2,lowPrice2,closePrice2,1);

    采用這種方式,編譯通不過,提示“未定義的變量:OPENPRICE2”!請(qǐng)問問題出在哪兒了?

     

     

  • 網(wǎng)友回復(fù):

    你的數(shù)組用法是有問題的,因?yàn)槎x的數(shù)組與序列變量還是有些區(qū)別

     

    openPrice2:=c;
    highPrice2:=c;
    lowPrice2:=c;
    closePrice2:=c;

     

    你這樣定義這4個(gè)變量為序列變量酒可以解決了

 

如果以上指標(biāo)公式不適用于您常用的行情軟件

或者您想改編成選股公式,以便快速選出某種形態(tài)個(gè)股的話,

可以聯(lián)系我們相關(guān)技術(shù)人員 QQ: 262069696  點(diǎn)擊在線交流進(jìn)行 有償 改編!

 


【字體: 】【打印文章】【查看評(píng)論

相關(guān)文章

    沒有相關(guān)內(nèi)容
主站蜘蛛池模板: 九九热视频这里只有精品 | 免费黄色一级大片 | 日韩在线看片中文字幕不卡 | www.色午夜 | 深夜精品寂寞在线观看黄网站 | 色久优优 欧美色久优优 | 亚洲成人伊人网 | 嫩模在线| 亚洲一区二区三区在线网站 | 黄色直接观看 | 日韩中文字幕精品一区在线 | 九九国产在线视频 | 美国成人a免费毛片 | 久久美剧免费在线观看 | 六月丁香深爱六月综合激情 | 国产亚洲精品美女2020久久 | 四虎一影院区永久精品 | 在线毛片免费观看 | 久久成人激情视频 | 欧美午夜精品久久久久免费视 | 四虎影视久久 | 久久久国产一区二区三区 | 成人在线视频免费观看 | 91成年人 | 荡女人人爱np粗口 | 亚洲国产福利精品一区二区 | 免费 黄 色 人成 视频 | 日韩欧美黄色大片 | 麻豆精品一区二区三区免费 | 99久久国产亚洲综合精品 | 这里只有精品在线播放 | 青青青爽在线视频观看 | 亚洲免费高清 | 亚洲欧美成人综合久久久 | s8国产成人精品视频 | 欧美大陆日韩一区二区三区 | 亚洲狠狠网站色噜噜 | 久久久久免费视频 | 久青草视频在线观看 | 琪琪色播 | 久久这里只有精品18 |