RSI Crosses SMA Buy/Sell Strategy-R-AlgoAIDisclaimer:
// This script is for educational and informational purposes only.
// It does not constitute financial or investment advice.
// Trading involves substantial risk and may not be suitable for all investors.
// Always do your own research or consult with a licensed financial advisor
// before making any trading or investment decisions.
// The author is not responsible for any losses incurred using this script
Key Changes:
Buy at High of the Signal Candle:
The strategy.entry("Buy", strategy.long, limit=high, comment="Buy at High of Signal Candle") line places a buy order at the high of the candle that triggered the signal (i.e., the candle where the RSI crosses above the SMA).
How it works:
When the RSI crosses above the SMA and the buy condition is true, the strategy will place a buy order at the high of that candle.
Exit:
The strategy will exit the position if the RSI crosses below the SMA as usual using strategy.close("Buy").
Example:
If the RSI crosses above the SMA at a specific candle, the strategy will enter a buy order at the high of that candle.
When the RSI crosses below the SMA, it will close the long position.
This should now execute a buy order at the high of the signal candle when the RSI crosses above the SMA, as requested.
Indicators and strategies
RSI Crosses SMA Buy/Sell StrategyDisclaimer:
// This script is for educational and informational purposes only.
// It does not constitute financial or investment advice.
// Trading involves substantial risk and may not be suitable for all investors.
// Always do your own research or consult with a licensed financial advisor
// before making any trading or investment decisions.
// The author is not responsible for any losses incurred using this script
Key Changes:
Buy at High of the Signal Candle:
The strategy.entry("Buy", strategy.long, limit=high, comment="Buy at High of Signal Candle") line places a buy order at the high of the candle that triggered the signal (i.e., the candle where the RSI crosses above the SMA).
How it works:
When the RSI crosses above the SMA and the buy condition is true, the strategy will place a buy order at the high of that candle.
Exit:
The strategy will exit the position if the RSI crosses below the SMA as usual using strategy.close("Buy").
Example:
If the RSI crosses above the SMA at a specific candle, the strategy will enter a buy order at the high of that candle.
When the RSI crosses below the SMA, it will close the long position.
This should now execute a buy order at the high of the signal candle when the RSI crosses above the SMA, as requested.
Fair Value Gap Retest DetectorFair Value Gaps (FVGs) represent price inefficiencies where buying and selling volumes are imbalanced, creating gaps between the wicks of consecutive candles. These gaps often act as magnets for price, as markets tend to "fill" these gaps before resuming their trend.
FVGs can signal potential entry or exit points, making them a valuable tool for traders looking to exploit these price inefficiencies.
S&P 500 Top 25 - EPS AnalysisEarnings Surprise Analysis Framework for S&P 500 Components: A Technical Implementation
The "S&P 500 Top 25 - EPS Analysis" indicator represents a sophisticated technical implementation designed to analyze earnings surprises among major market constituents. Earnings surprises, defined as the deviation between actual reported earnings per share (EPS) and analyst estimates, have been consistently documented as significant market-moving events with substantial implications for price discovery and asset valuation (Ball and Brown, 1968; Livnat and Mendenhall, 2006). This implementation provides a comprehensive framework for quantifying and visualizing these deviations across multiple timeframes.
The methodology employs a parameterized approach that allows for dynamic analysis of up to 25 top market capitalization components of the S&P 500 index. As noted by Bartov et al. (2002), large-cap stocks typically demonstrate different earnings response coefficients compared to their smaller counterparts, justifying the focus on market leaders.
The technical infrastructure leverages the TradingView Pine Script language (version 6) to construct a real-time analytical framework that processes both actual and estimated EPS data through the platform's request.earnings() function, consistent with approaches described by Pine (2022) in financial indicator development documentation.
At its core, the indicator calculates three primary metrics: actual EPS, estimated EPS, and earnings surprise (both absolute and percentage values). This calculation methodology aligns with standardized approaches in financial literature (Skinner and Sloan, 2002; Ke and Yu, 2006), where percentage surprise is computed as: (Actual EPS - Estimated EPS) / |Estimated EPS| × 100. The implementation rigorously handles potential division-by-zero scenarios and missing data points through conditional logic gates, ensuring robust performance across varying market conditions.
The visual representation system employs a multi-layered approach consistent with best practices in financial data visualization (Few, 2009; Tufte, 2001).
The indicator presents time-series plots of the four key metrics (actual EPS, estimated EPS, absolute surprise, and percentage surprise) with customizable color-coding that defaults to industry-standard conventions: green for actual figures, blue for estimates, red for absolute surprises, and orange for percentage deviations. As demonstrated by Padilla et al. (2018), appropriate color mapping significantly enhances the interpretability of financial data visualizations, particularly for identifying anomalies and trends.
The implementation includes an advanced background coloring system that highlights periods of significant earnings surprises (exceeding ±3%), a threshold identified by Kinney et al. (2002) as statistically significant for market reactions.
Additionally, the indicator features a dynamic information panel displaying current values, historical maximums and minimums, and sample counts, providing important context for statistical validity assessment.
From an architectural perspective, the implementation employs a modular design that separates data acquisition, processing, and visualization components. This separation of concerns facilitates maintenance and extensibility, aligning with software engineering best practices for financial applications (Johnson et al., 2020).
The indicator processes individual ticker data independently before aggregating results, mitigating potential issues with missing or irregular data reports.
Applications of this indicator extend beyond merely observational analysis. As demonstrated by Chan et al. (1996) and more recently by Chordia and Shivakumar (2006), earnings surprises can be successfully incorporated into systematic trading strategies. The indicator's ability to track surprise percentages across multiple companies simultaneously provides a foundation for sector-wide analysis and potentially improves portfolio management during earnings seasons, when market volatility typically increases (Patell and Wolfson, 1984).
References:
Ball, R., & Brown, P. (1968). An empirical evaluation of accounting income numbers. Journal of Accounting Research, 6(2), 159-178.
Bartov, E., Givoly, D., & Hayn, C. (2002). The rewards to meeting or beating earnings expectations. Journal of Accounting and Economics, 33(2), 173-204.
Bernard, V. L., & Thomas, J. K. (1989). Post-earnings-announcement drift: Delayed price response or risk premium? Journal of Accounting Research, 27, 1-36.
Chan, L. K., Jegadeesh, N., & Lakonishok, J. (1996). Momentum strategies. The Journal of Finance, 51(5), 1681-1713.
Chordia, T., & Shivakumar, L. (2006). Earnings and price momentum. Journal of Financial Economics, 80(3), 627-656.
Few, S. (2009). Now you see it: Simple visualization techniques for quantitative analysis. Analytics Press.
Gu, S., Kelly, B., & Xiu, D. (2020). Empirical asset pricing via machine learning. The Review of Financial Studies, 33(5), 2223-2273.
Johnson, J. A., Scharfstein, B. S., & Cook, R. G. (2020). Financial software development: Best practices and architectures. Wiley Finance.
Ke, B., & Yu, Y. (2006). The effect of issuing biased earnings forecasts on analysts' access to management and survival. Journal of Accounting Research, 44(5), 965-999.
Kinney, W., Burgstahler, D., & Martin, R. (2002). Earnings surprise "materiality" as measured by stock returns. Journal of Accounting Research, 40(5), 1297-1329.
Livnat, J., & Mendenhall, R. R. (2006). Comparing the post-earnings announcement drift for surprises calculated from analyst and time series forecasts. Journal of Accounting Research, 44(1), 177-205.
Padilla, L., Kay, M., & Hullman, J. (2018). Uncertainty visualization. Handbook of Human-Computer Interaction.
Patell, J. M., & Wolfson, M. A. (1984). The intraday speed of adjustment of stock prices to earnings and dividend announcements. Journal of Financial Economics, 13(2), 223-252.
Skinner, D. J., & Sloan, R. G. (2002). Earnings surprises, growth expectations, and stock returns or don't let an earnings torpedo sink your portfolio. Review of Accounting Studies, 7(2-3), 289-312.
Tufte, E. R. (2001). The visual display of quantitative information (Vol. 2). Graphics Press.
Climax Detector (Buy & Sell)This indicator identifies potential Buying Climax (BC) and Selling Climax (SC) events based on volume spikes relative to historical averages.
• Buying Climax (BC):
• Detected when a green candle forms with volume significantly higher than the average (default: 2×).
• Often signals the end of an uptrend or distribution phase.
• Selling Climax (SC):
• Detected when a red candle forms with very high volume (default: 2× average).
• Often occurs at the end of a downtrend, suggesting panic selling and potential accumulation.
How it works:
• Calculates a moving average of volume over a user-defined period (default: 20 candles)
• Flags a climax when current volume exceeds the defined multiplier (default: 2.0×)
• Marks:
• BC with an orange triangle above the bar
• SC with a fuchsia triangle below the bar
Customizable Settings:
• Volume spike sensitivity
• Lookback period for average volume
Use Cases:
• Spot possible trend exhaustion
• Confirm Wyckoff phases
• Combine with support/resistance for reversal entries
Disclaimer: This tool is designed to assist in identifying high-probability exhaustion zones but should be used alongside other confirmations or strategies.
1-AI Volume Supertrend - Strategy🤖 AI Volume Indicator — Description for Publishing
Description:
The AI Volume Indicator leverages enhanced logic to analyze market volume with a focus on uncovering hidden accumulation, distribution, and momentum shifts. Unlike basic volume bars, this indicator applies adaptive algorithms or pattern recognition (AI-inspired) to highlight significant volume events that may precede price movements.
2-(Smart Money Concepts)(VWAP)(HMA)The Relative Strength Index (RSI) is a momentum oscillator that measures the speed and change of price movements. It ranges from 0 to 100 and is typically used to identify overbought or oversold market conditions.
Overbought levels: RSI above 70 suggests the asset may be overbought and a price correction could follow.
VWAP Buy with Profit Target and Stop LossThis strategy is helpful in intraday of swing for 2-3 days , choose stocks wisely like HDFC bank ICICI bank to get profitable trade more than 70% and profit factor more than 1.2
6 Exponential Moving Averages 2 SMA6 EMA Trend Indicator
This indicator plots 6 Exponential Moving Averages (EMAs) with customizable periods to help traders visually analyze short-, medium-, and long-term trend alignments. Ideal for identifying trend strength, pullback zones, and dynamic support/resistance.
Features:
• 6 fully adjustable EMA inputs
• Clear color-coded visualization
• Works on all timeframes
• Effective for trend trading and scalping
Use it to confirm trend direction, spot EMA crossovers, or align multiple EMAs for high-probability entries.
Mayfair COT ToolCommitments of traders gives the positions of the professionals (default is Leveraged Traders) so you can see what the BIG boys are thinking.
All‑MA Crossover + analyzer + risk Management [quantotc]🔍 Overview
All‑MA Trend Analyzer + Risk Management is a full-featured, multi-purpose trend and crossover system that lets you compare 8 different moving average types, visualize their alignment across timeframes, and apply robust risk management strategies — all in one powerful tool.
🧠 What Makes This Indicator Unique?
🔄 8 Moving Average Types — Easily switch between SMA, EMA, WMA, VWMA, HMA, RMA, SMMA, and TMA.
🟢 Signal Clarity — Buy/Sell labels appear on fast/slow MA crossovers.
📊 Dual Analysis Tables
Top-right: Multi-timeframe crossover trends (15m, 1h, 4h, Daily)
Bottom-right: MA type trends on current timeframe (Bull/Bear)
⚙️ Risk Management
Supports fixed SL/TP or trailing stop-loss
Works in % or Points
Visual SL/TP/TSL exit labels with separate alerts
🎯 How to Use
Select your desired MA Type (e.g., TMA, VWMA, etc.)
Adjust Fast/Slow Lengths depending on your strategy
Enable Long/Short entries as needed
Choose SL/TP Mode: Points or Percentage
Enable Trailing Stop for dynamic protection
Each feature is grouped and labeled with tooltips in the settings panel for clarity.
🖼 Visual Aids
A TMA Bull signal
Table-based trend analysis
Buy label clarity
Sell label clarity
Exit label on Take Profit
Exit label on Stop Loss
Trailing Stop Loss Exit
🚨 Alerts Included
BUY / SELL
TAKE PROFIT
STOPLOSS
TRAILING STOPLOSS
Each is customizable in the settings.
👤 Developer Info
Developer: quantotc
Website: quantotc.com
YouTube:https://youtube.com/@quantotc
Tags: multi timeframe, crossover, risk management, all MA, trailing stop, bullish bearish, trend table, strategy builder
⚠️ Disclaimer
This script is for educational purposes only. No guarantee of profitability. Always backtest and use proper risk management.
Prototype 005This is a tool that will make it easy for you to trade by identifying the position of the buy and sell points of the order.
Burr ORB RSIRSI To monitor overbought or oversold conditions. Prevents staying in a trade when price is likely to reverse.
Burr ORB MomentumShows momentum in seperate pane. Useful when trading ORB breakout to determine strength of trend and probability of continuation or reversal.
Burr Orb VolumeVolume Histogram used to confirm strong Breakouts of the ORB. Highlights Volume Spikes for added confirmation.
Burr ORBMarks the ORB on desired timeframe. Also marks the previous days High and Low for reference during Session
Kijun-Sen Filter for ScalpingThis is designed to assist lower time framed trading strategies with general trend sentiment. The baseline indicator used in this script is the trust Kijun-Sen. The baseline is best to be used on the daily timeframe however you can select whichever you prefer the same applies to the period as well.
You will see a table in the top right of the screen letting you know the trend direction.
Bullish
Bearish
Vortex SMA StrategyThere are two components to this script:
- Vortex Indicator (This will signal the long and short entries)
- SMA (This acts as a filter when price is above the SMA it only signals longs, when the price is below the SMA it only signals shorts)
Examples of longs and shorts
It's best to use a volume indicator paired with this to further filter losing trades.
If you have any ideas send me a message please!
Middle Finger Trading StrategyStrategy Logic Summary:
Identify Huge Volume: Finds a bar ( - the previous bar) where volume is significantly higher (activeHugeVolMultiplier) than the recent average volume (avgVolume ). The average calculation excludes specific times (RTH edges, certain ETH).
Confirm Volume Drop: Checks if the current bar's ( ) volume is lower than the previous bar's huge volume (volume < volume ).
Determine Trend Before Spike: Looks at the close two bars ago (close ) relative to the SMA two bars ago (priceSma ) to determine the trend before the huge volume bar.
Entry Signal (Base):
Long: Bearish trend before spike + Huge Volume on prev bar + Volume drop on current bar.
Short: Bullish trend before spike + Huge Volume on prev bar + Volume drop on current bar.
Time Filter: Optionally filters out entries during the first/last 15 mins of RTH and always filters specific ETH/pre-market times.
Entry Execution:
If a Long signal occurs and no position is open, place a limit order to buy at the low of the huge volume bar (low ).
If a Short signal occurs and no position is open, place a limit order to sell at the high of the huge volume bar (high ).
Order Processing: process_orders_on_close=false means limit orders can potentially be filled intra-bar if the price touches the limit level during the bar's formation.
FVG [TakingProphets]🧠 Purpose
This indicator is built for traders applying Inner Circle Trader (ICT) methodology. It detects and manages Fair Value Gaps (FVGs) — price imbalances that often act as future reaction zones. It also highlights New Day Opening Gaps (NDOGs) and New Week Opening Gaps (NWOGs) that frequently play a role in early-session price behavior.
📚 What is a Fair Value Gap?
A Fair Value Gap forms when price moves rapidly, skipping over a portion of the chart between three candles — typically between the high of the first candle and the low of the third. These zones are considered inefficient, meaning institutions may return to them later to:
-Rebalance unfilled orders
-Enter or scale into positions
-Engineer liquidity with minimal slippage
In ICT methodology, FVGs are seen as both entry zones and targets, depending on market structure and context.
⚙️ How It Works
-This script automatically identifies and manages valid FVGs using the following logic:
-Bullish FVGs: When the low of the current candle is above the high from two candles ago
-Bearish FVGs: When the high of the current candle is below the body of two candles ago
-Minimum Gap Filter: Gaps must be larger than 0.05% of price
-Combine Consecutive Gaps (optional): Merges adjacent gaps of the same type
-Consequent Encroachment Line (optional): Plots the midpoint of each gap
-NDOG/NWOG Tracking: Labels gaps created during the 5–6 PM session transition
-Automatic Invalidation: Gaps are removed once price closes beyond their boundary
🎯 Practical Use
-Use unmitigated FVGs as potential entry points or targets
-Monitor NDOG and NWOG for context around daily or weekly opens
-Apply the midpoint (encroachment) line for precise execution decisions
-Let the script handle cleanup — only active, relevant zones remain visible
🎨 Customization
-Control colors for bullish, bearish, and opening gaps
-Toggle FVG borders and midpoint lines
-Enable or disable combining of consecutive gaps
-Fully automated zone management, no manual intervention required
✅ Summary
This tool offers a clear, rules-based approach to identifying price inefficiencies rooted in ICT methodology. Whether used for intraday or swing trading, it helps traders stay focused on valid, active Fair Value Gaps while filtering out noise and maintaining chart clarity.
No gaps candlescreate a script myself so I can take more control on the indicator. updated to version 6, keep the same logic from the creator. you can search the same title, he has like 1K use
EMA 20/50simple EMA, that's all I need. only 20 and 50 EMA, very easy to understand the trend. also fit better with my strategy, I trade 15mins+ TH.