[問題] 原諒小弟愚蠢QQ~問一下這幾段程式

看板Trading作者 (水果XD)時間12年前 (2011/10/30 19:48), 編輯推噓2(201)
留言3則, 3人參與, 最新討論串1/1
請問這幾段程式的買進賣出的條件是@@? 因為我不熟悉語法>"< 1. RSI Inputs: RSILength(10), OverSold(30); If Currentbar > 1 AND RSI(Close, RSILength) Cross Over OverSold Then Buy ("RSIbuy") This Bar on Close; Inputs: OverBought(70); If Currentbar > 1 AND RSI(Close, RSILength) Cross Below OverBought Then Sell ("RSIsell") This Bar on Close; ================================================================= 2. KD Inputs: Length(14), OverBought(70),OverSold(30); Variables: KLine(0), DLine(0); KLine = SlowKCustom(High, Low, Close, Length); DLine = SlowDCustom(High, Low, Close, Length); If KLine Crosses Below DLine AND KLine > OverBought AND DLine > OverBought Then Sell ("Sellkd") This Bar on Close; If KLine Crosses Above DLine AND KLine < OverSold AND DLine < OverSold Then Buy ("buykd") This Bar on Close; ================================================================== 3. MACD Inputs: FastMovAvg(12), SlowMovAvg(26), MACDMovAvg(9); Variables: XMACD(0); If CurrentBar > 2 AND MACD(Close, FastMovAvg, SlowMovAvg) Crosses Above XAverage(MACD(Close, FastMovAvg, SlowMovAvg), MACDMovAvg)[1] Then Buy ("MACDbuy") This Bar on Close; If CurrentBar > 2 AND MACD(Close, FastMovAvg, SlowMovAvg) Crosses Below XAverage(MACD(Close, FastMovAvg, SlowMovAvg), MACDMovAvg)[1] Then Sell ("MACDsell") This Bar on Close; ================================================================== 4. CCI Inputs: CCILen(20), FastLen(10), SlowLen(20); Variables: CCIVal(0); CCIVal = CCI(CCILen); If AverageFC(CCIVal, FastLen) Crosses AboveAverageFC(CCIVal, SlowLen) Then Buy ("CCIbuy") This Bar on Close; CCIVal = CCI(CCILen); If AverageFC(CCIVal, FastLen) Crosses BelowAverageFC(CCIVal, SlowLen) Then Sell ("CCIsell") This Bar on Close; ================================================================== 5. DMI Inputs: DMILen(14), Consec(3), MinDiff(0); Variables: DMIDiff(0); DMIDiff = DMIPlus(DMILen) - DMIMinus(DMILen); If DMIDiff[Consec] > 0 Then Begin If DMIDiff >= MinDiff AND CountIF(DMIDiff > DMIDiff[1], Consec) = Consec Then Buy ("DMIbuy") This Bar on Close; End; DMIDiff = DMIPlus(DMILen) - DMIMinus(DMILen); If DMIDiff[Consec] < 0 Then Begin If AbsValue(DMIDiff) >= MinDiff AND CountIF(DMIDiff < DMIDiff[1], Consec) = Consec Then Sell ("DMIsell") This Bar on Close; End; =================================================================== 拜託大家了>"< -- (Gossiping) [ptt.cc] [新聞] 陳致中參選 衝擊民進黨選票 → Ebisu:他選的上我請樓下每人一桶KFC 05/12 11:05 推 Dillon0801:他會請的話 =====我請大家吃麥當勞超值全餐===== 05/12 11:18 推 nopass:只要Ebisu請以上這些人一人一桶kfc 我就請下面的人吃雞腿堡 05/12 11:47 推 debris:Ebisu有請每人一桶kfc的話 我請下面的人吃鼎王 ZZZzzzzz 05/12 12:02 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 123.110.15.194

10/30 20:07, , 1F
好眼熟唷~這應該是TS裡面的吧 :)
10/30 20:07, 1F

10/30 20:14, , 2F
對啊@@~
10/30 20:14, 2F

10/30 22:10, , 3F
http://ppt.cc/lJe5 看完就懂了,歡迎加入程式交易^^
10/30 22:10, 3F
文章代碼(AID): #1EhJcYId (Trading)