到奇狐勝券首頁 奇狐社區論壇 購買奇狐勝券 試用奇狐勝券
 
論壇首頁 你可以在這裡編輯你的資料,查看短訊,訂閱主題和論壇參數等等 免費會員註冊 會員列表 論壇幫助 論壇日曆 論壇搜索 加入我的最愛 登出論壇  
奇狐社區論壇 : Powered by vBulletin version 2.3.0 奇狐社區論壇 > 指標公式 > 問題交流 > [教學]總版主.peter 大哥.各位路過的高手請幫幫忙
  上一主題   下一主題
作者
主題 發表新主題    回覆主題
Markchu7
資深會員

註冊日期: Nov 2007
來  自:
文章數量: 1501

[教學]總版主.peter 大哥.各位路過的高手請幫幫忙

下列的源碼的意思?(報告總版主不知正確應該在那一版面發問,請移至正確版面!),感恩!
cc:=c;
oo:=o;
hh:=h;
ll:=l;
top:h,linethick;
bot:l,linethick;
xx[1]:=1;
kk:=1;
for i=1 to datacount do begin if xx[i]=1 then begin top[i]:=hh[i];
end;
if xx[i-1]=1 then begin if hh[i]>top[i-1] then begin top[i]:=hh[i];
xx[i]:1;
end;
else begin top[i]:=top[i-1];
xx[i]:=2;
end;
end;
if xx[i-1]=2 then begin if hh[i]>top[i-1] then begin top[i]:=hh[i];
xx[i]:=1;
end;
else begin top[i]:=top[i-1];
bot[i]:=ll[i];
xx[i]:=3;
end;
end;
if xx[i-1]=3 then begin top[i]:=top[i-1];
if ll[i]<bot[i-1] then begin bot[i]:=ll[i];
xx[i]:=3;
end;
else begin bot[i]:=bot[i-1];
xx[i]:=4;
end;
end;
if xx[i-1]=4 then begin top[i]:=top[i-1];
if ll[i]<bot[i-1] then begin bot[i]:=ll[i];
xx[i]:=3;
end;
else begin bot[i]:=bot[i-1];
xx[i]:=5;
end;
end;
if xx[i-1]=5 then begin if ll[i]<bot[i-1] or hh[i]>top[i-1] then begin top[i]:=hh[i];
bot[i]:=hh[i];
xx[i]:=1;
end;
else begin bot[i]:=bot[i-1];
top[i]:=top[i-1];
xx[i]:=5;
end;
end;
end;
for j=1 to datacount do begin if xx[j]=5 and xx[j-1]=4 then begin for k=j-1 downto j-kk do begin top[k]:=top[j];
bot[k]:=bot[j];
end;
end;
if xx[j-1]=5 and xx[j]=1 then kk:=0;
kk:=kk+1;
end;

中位線:=(top+bot)/2;

PARTLINE(top=ref(top,1),top),COLORBLACK,LINEDOT;
PARTLINE(bot=ref(bot,1),bot),COLORBLACK,LINEDOT;

STICKLINE((top<>ref(top,1) or bot<>ref(bot,1)) and xx=1 and ref(xx,1)=5,top,bot,1,0),COLORBLACK,LINEDOT;
STICKLINE((top<>refx(top,1) or bot<>refx(bot,1)) and xx=5 and refx(xx,1)=1,top,bot,1,0),COLORBLACK,LINEDOT;
PARTLINE(top=ref(top,1) ,中位線),COLORBLACK,LINEDOT;

向版主報告此篇 | 查IP位址
Old Post 2013-08-09 08:03
Markchu7 現在離線 點選這裡查看 Markchu7 的個人資料 點選這裡給 Markchu7 傳送一條短訊 查找更多關於 Markchu7 的文章 增加 Markchu7 至你的好友列表 編輯/刪除訊息 引用回覆
cgjj
總版主

註冊日期: Oct 2003
來  自:
文章數量: 18114

回覆: [教學]總版主.peter 大哥.各位路過的高手請幫幫忙

引用:
最初由 Markchu7 發表
下列的源碼的意思?(報告總版主不知正確應該在那一版面發問,請移至正確版面!),感恩!
cc:=c;
oo:=o;
hh:=h;
ll:=l;
top:h,linethick;
bot:l,linethick;
xx[1]:=1;
kk:=1;
for i=1 to datacount do begin if xx[i]=1 then begin top[i]:=hh[i];
end;
if xx[i-1]=1 then begin if hh[i]>top[i-1] then begin top[i]:=hh[i];
xx[i]:1;
end;
else begin top[i]:=top[i-1];
xx[i]:=2;
end;
end;
if xx[i-1]=2 then begin if hh[i]>top[i-1] then begin top[i]:=hh[i];
xx[i]:=1;
end;
else begin top[i]:=top[i-1];
bot[i]:=ll[i];
xx[i]:=3;
end;
end;
if xx[i-1]=3 then begin top[i]:=top[i-1];
if ll[i]<bot[i-1] then begin bot[i]:=ll[i];
xx[i]:=3;
end;
else begin bot[i]:=bot[i-1];
xx[i]:=4;
end;
end;
if xx[i-1]=4 then begin top[i]:=top[i-1];
if ll[i]<bot[i-1] then begin bot[i]:=ll[i];
xx[i]:=3;
end;
else begin bot[i]:=bot[i-1];
xx[i]:=5;
end;
end;
if xx[i-1]=5 then begin if ll[i]<bot[i-1] or hh[i]>top[i-1] then begin top[i]:=hh[i];
bot[i]:=hh[i];
xx[i]:=1;
end;
else begin bot[i]:=bot[i-1];
top[i]:=top[i-1];
xx[i]:=5;
end;
end;
end;
for j=1 to datacount do begin if xx[j]=5 and xx[j-1]=4 then begin for k=j-1 downto j-kk do begin top[k]:=top[j];
bot[k]:=bot[j];
end;
end;
if xx[j-1]=5 and xx[j]=1 then kk:=0;
kk:=kk+1;
end;

中位線:=(top+bot)/2;

PARTLINE(top=ref(top,1),top),COLORBLACK,LINEDOT;
PARTLINE(bot=ref(bot,1),bot),COLORBLACK,LINEDOT;

STICKLINE((top<>ref(top,1) or bot<>ref(bot,1)) and xx=1 and ref(xx,1)=5,top,bot,1,0),COLORBLACK,LINEDOT;
STICKLINE((top<>refx(top,1) or bot<>refx(bot,1)) and xx=5 and refx(xx,1)=1,top,bot,1,0),COLORBLACK,LINEDOT;
PARTLINE(top=ref(top,1) ,中位線),COLORBLACK,LINEDOT;



源碼的意思?
@@ 真不知要回應您什麼

就是用來計算畫面輸出的結果
結果是什麼意義, 請洽原作者

向版主報告此篇 | 查IP位址
Old Post 2013-08-09 10:31
cgjj 現在離線 點選這裡查看 cgjj 的個人資料 點選這裡給 cgjj 傳送一條短訊 查找更多關於 cgjj 的文章 增加 cgjj 至你的好友列表 編輯/刪除訊息 引用回覆
Markchu7
資深會員

註冊日期: Nov 2007
來  自:
文章數量: 1501

感謝總版主的回覆!這是網路上下載來的啦!如果有原作者可以問我還真的是感謝上帝了!只不過是半路出師的半吊子想要學習一下罷了!總版主不是常說:錯的不知所以然更糟糕嗎?不好意思浪費版面了!看得懂的大大們如果覺得有用就來去用用看吧!

最後由 Markchu7 在 2013-08-09 11:42 編輯 向版主報告此篇 | 查IP位址
Old Post 2013-08-09 11:38
Markchu7 現在離線 點選這裡查看 Markchu7 的個人資料 點選這裡給 Markchu7 傳送一條短訊 查找更多關於 Markchu7 的文章 增加 Markchu7 至你的好友列表 編輯/刪除訊息 引用回覆
mead
資深會員

註冊日期: Nov 2004
來  自: 台北
文章數量: 409

這是一段畫箱體的程式碼
主要是要了解他箱體的定義
不然就只能照著用了

向版主報告此篇 | 查IP位址
Old Post 2013-08-09 15:43
mead 現在離線 點選這裡查看 mead 的個人資料 點選這裡給 mead 傳送一條短訊 查找更多關於 mead 的文章 增加 mead 至你的好友列表 編輯/刪除訊息 引用回覆
Markchu7
資深會員

註冊日期: Nov 2007
來  自:
文章數量: 1501

感謝M大的回覆,我知道是畫箱體!因為門外漢一點一滴學著奇狐的寫法,很辛苦!看不懂源碼,無法知悉畫箱體的規則,所以PO上來,看看有無高手可以指點迷津,否則就算分享也是不錯!

向版主報告此篇 | 查IP位址
Old Post 2013-08-09 17:31
Markchu7 現在離線 點選這裡查看 Markchu7 的個人資料 點選這裡給 Markchu7 傳送一條短訊 查找更多關於 Markchu7 的文章 增加 Markchu7 至你的好友列表 編輯/刪除訊息 引用回覆
mead
資深會員

註冊日期: Nov 2004
來  自: 台北
文章數量: 409

那應該是VBS語法寫的 我也不是很懂!
所以無法解說
希望能有懂的大大能提點一下 好讓我們能自行修改成自己要的!

向版主報告此篇 | 查IP位址
Old Post 2013-08-09 23:36
mead 現在離線 點選這裡查看 mead 的個人資料 點選這裡給 mead 傳送一條短訊 查找更多關於 mead 的文章 增加 mead 至你的好友列表 編輯/刪除訊息 引用回覆
cgjj
總版主

註冊日期: Oct 2003
來  自:
文章數量: 18114

引用:
最初由 mead 發表
那應該是VBS語法寫的 我也不是很懂!
所以無法解說
希望能有懂的大大能提點一下 好讓我們能自行修改成自己要的!



該段程式並未用到 VBS 唷
(這邊講的 VBS 是指 VBScript)

向版主報告此篇 | 查IP位址
Old Post 2013-08-12 09:39
cgjj 現在離線 點選這裡查看 cgjj 的個人資料 點選這裡給 cgjj 傳送一條短訊 查找更多關於 cgjj 的文章 增加 cgjj 至你的好友列表 編輯/刪除訊息 引用回覆
mead
資深會員

註冊日期: Nov 2004
來  自: 台北
文章數量: 409

是喔!見笑了
請大家忽略我的言論

向版主報告此篇 | 查IP位址
Old Post 2013-08-12 11:20
mead 現在離線 點選這裡查看 mead 的個人資料 點選這裡給 mead 傳送一條短訊 查找更多關於 mead 的文章 增加 mead 至你的好友列表 編輯/刪除訊息 引用回覆
全部時間均為台灣時間, 現在時間為15:17 發表新主題    回覆主題
  上一主題   下一主題
顯示可列印版本 | 訂閱此主題

論壇跳轉:
主題評分:

論壇規定:
你不可以發表新主題
你不可以回覆文章
你不可以上傳附件
你不可以編輯自己的文章
HTML語法禁止
vB 語法核准
表情符號核准
貼圖語法[IMG]核准
 

本站所有內容未經作者授權禁止轉貼節錄, 發表言論僅供參考勿作為投資決策依據。瀏覽本站請使用 IE 5.5 以上版本, 最佳瀏覽解析度 1024 x 768 全彩。

Powered by: vBulletin Version 2.3.0 - Copyright©2000-, Jelsoft Enterprises Limited.

簡愛洋行 製作 Copyright 2003-. All Rights Reserved.  聯絡我們