KP Double Blade X

725
KP Double Blade (KP-DB)

OVERVIEW
KP Double Blade is a two-layer, trend-following entry tool built and tuned for XAUUSD (Gold) on intraday charts (default: 5-minute chart, 15-minute bias). The idea is simple: one "blade" decides the direction, the other decides the timing.

• Blade 1 – HTF Bias (MACD): a higher-timeframe MACD decides whether the script is allowed to look for Buys, Sells, or nothing.
• Blade 2 – Stochastic timing: a Stochastic %K/%D cross on the entry timeframe triggers entries only in the direction of the active bias, and also provides the exit signal.

Every simulated trade is drawn on the chart with its result in POINTS (+/-), not in money.

HOW IT WORKS
1) Bias (default 15m MACD 12/26/9)
• Sell bias starts when MACD crosses below its signal line AND the previous positive MACD wave peaked above "Prev wave peak" (default 5.0). Buy bias is the mirror image (previous negative wave below -5.0).
• Each wave can trigger only one bias.
• Bias ends when MACD reaches the "Deep level" and crosses back, or when MACD returns to the "Exit" level on the opposite side.
• Spike filter: a new bias is skipped if a recent bar was a spike (Open-High/Open-Low larger than X points, or High-Low larger than ATR(14) x N). Can be switched off.
• The background turns red (Sell bias) or teal (Buy bias).

2) Entry (default 5m Stochastic 9/3/3)
• Buy: %K crosses up through %D below 30 while bias = Buy.
• Sell: %K crosses down through %D above 70 while bias = Sell.
• Optional filters: MACD level filter at the cross, and an entry-timing filter (Hook / Slope / Decel / Arm & Wait) based on the entry-timeframe MACD.

3) Exit
• STO – opposite Stochastic cross in the exit zone (Buy exit at/above 60, Sell exit at/below 30).
• SL – fixed initial stop in points (default 10.0).
• BE – optional break-even move after X points in profit.
• END – when the bias ends, the trade is closed only if it is in profit (optional).

Label format: "B STO +6.78" = Buy, closed by Stochastic exit, +6.78 points.

POINTS DEFINITION
All distances (SL, BE, spike filter, spread cost, results) are in PRICE UNITS of the chart symbol. On XAUUSD, 1.00 point = a 1.00 move in price (e.g. 3900.00 → 3901.00). This is NOT the same as an MT5 "point" (0.01) or a "pip". Results are shown in points only, so they do not depend on lot size or account currency.

NON-REPAINTING NOTES
• Higher-timeframe values are taken from the last CLOSED bar of each timeframe (request.security with offset [1] + lookahead_on), so signals do not repaint after the bar closes.
• Simulated entries and exits fill at the OPEN of the next chart bar. Stops are checked with bar high/low; if a bar gaps beyond the stop, the fill is the bar open.
• The Stochastic timeframe must be equal to or higher than the chart timeframe. A warning label appears if it is not.

SETTINGS TIPS
• "Start from" limits where trades start being drawn.
• "Cost per trade" lets you subtract your average spread (in points) from every result.
• Alerts: create an alert with "Any alert() function call" to receive bias, entry, exit and BE messages, or use the individual alertcondition() entries.

IMPORTANT – PLEASE READ
• The default settings were developed and tested ONLY on XAUUSD, mainly on the 5-minute chart with a 15-minute bias. Values such as the MACD peak/deep/exit levels, spike size, SL and BE are absolute numbers that fit Gold's price scale and volatility.
• On ANY other symbol (forex, indices, crypto, stocks, other metals) or other timeframes, these defaults will very likely be wrong. You must test and find your own values. No compatibility with other instruments is claimed or guaranteed.
• Results differ between brokers/data feeds, sessions and market regimes. Past behaviour does not predict future results.
• The on-chart trades are a simplified simulation for studying the logic. They do not include slippage, commissions, swaps, partial fills or intrabar order of price movement, and they are not a full strategy backtest.
• This script is a study/educational tool, not financial advice and not a buy/sell recommendation. Trading leveraged products such as Gold CFDs carries a high risk of loss. Always do your own testing, use proper risk management, and trade at your own risk.

------------------------------------------------------------
(ภาษาไทย – สรุป)

KP Double Blade เป็นอินดิเคเตอร์ตามเทรนด์ 2 ชั้น ออกแบบและจูนค่ามาเพื่อ XAUUSD โดยเฉพาะ (ค่าเริ่มต้น: กราฟ M5, Bias M15)
• ใบมีดที่ 1 – MACD TF ใหญ่ กำหนดว่าตอนนี้หาแต่ Buy, แต่ Sell หรือไม่เทรด
• ใบมีดที่ 2 – Stochastic cross ใน TF เข้า ใช้จับจังหวะเข้าตาม Bias และใช้เป็นสัญญาณออก
ผลแต่ละไม้แสดงเป็น "จุด" (+/-) ไม่แสดงเป็นเงิน โดย 1 จุด = ราคาขยับ 1.00 (เช่น 3900 → 3901)

ข้อควรทราบ
• ค่าตั้งต้นทั้งหมดทดสอบกับ XAUUSD เท่านั้น ถ้านำไปใช้กับสินทรัพย์หรือ TF อื่น ต้องทดลองและหาค่าใหม่เอง ไม่รับประกันว่าจะใช้ร่วมกันได้
• ไม้บนกราฟเป็นการจำลองแบบง่าย ไม่รวม slippage/ค่าคอม/swap ผลในอดีตไม่ได้รับประกันอนาคต
• ใช้เพื่อการศึกษา ไม่ใช่คำแนะนำการลงทุน การเทรดมีความเสี่ยงสูง โปรดบริหารความเสี่ยงและรับผิดชอบการตัดสินใจของตนเอง

כתב ויתור

המידע והפרסומים אינם מיועדים להיות, ואינם מהווים, ייעוץ או המלצה פיננסית, השקעתית, מסחרית או מכל סוג אחר המסופקת או מאושרת על ידי TradingView. קרא עוד ב־תנאי השימוש.