OPEN-SOURCE SCRIPT
Universal Sentiment Oscillator with Trade Recommendations

Universal Sentiment Oscillator & Strategy Guide
Summary
This all-in-one indicator is designed to be a comprehensive co-pilot for your trading journey. It moves beyond simple buy/sell signals by analyzing the underlying market sentiment and providing a dynamic, risk-assessed guide of potential trading strategies. Whether you're a novice learning the ropes or an expert seeking confirmation, this tool provides a structured framework for making smarter, more informed decisions in stocks, options, and futures.
How It Works
The core of the indicator is the Sentiment Oscillator, which calculates a score from -5 (Extremely Bearish) to +5 (Extremely Bullish) on every bar. This isn't just a single measurement; it's a weighted aggregate of several key technical conditions:
Trend Analysis: Price position relative to the 20, 50, and 200 EMAs.
Momentum Analysis: The current RSI value.
Hybrid Analysis: The state of the MACD and its signal line.
These factors are intelligently combined and normalized to produce a single, intuitive sentiment score, giving you an at-a-glance understanding of the market's pulse.
Core Features
Dynamic Trade Recommendation Table:
The informational heart of the indicator. This on-chart table provides a list of potential trades perfectly aligned with the current sentiment score.
Risk-Ranked Strategies:
All suggested trades are logically ordered by risk, helping you quickly identify strategies that match your comfort level.
Adjusted Trade Suggestions:
The indicator analyzes sentiment momentum (the score vs. its signal line) to provide proactive, forward-looking trade ideas based on where the market might be heading next.
Customizable Trading Styles:
Tell the indicator if you are a Conservative, Neutral, or Aggressive trader, and the "Adjusted Trade Suggestion" will automatically tailor its recommendations to your personal risk preference.
Context-Aware Futures Mode:
When viewing a futures contract, enable this mode to switch all recommendations from stock/options to futures-specific actions (e.g., "Cautious Long," "Monitor Range").
Predictive Sentiment Cone:
Visualize the potential short-term path of sentiment based on current momentum, helping you anticipate future conditions.
Fully Customizable:
Every parameter—from EMA lengths to trade filters—can be adjusted, allowing you to fine-tune the indicator to your exact specifications.
How to Use This Indicator
This tool is flexible and can be integrated into many trading systems. Here is a powerful, professional approach:
Top-Down Analysis (for Swing or Position Trading):
Establish the Trend: Start on the higher timeframes (Monthly, Weekly, Daily). Use the oscillator's color and score to define the dominant, long-term market sentiment. You only want to look for trades that align with this macro trend.
Refine the Entry: Drop down to the medium timeframes (4-Hour, 1-Hour). Wait for the sentiment on these charts to come into alignment with the higher-timeframe trend. This pullback or consolidation is your "zone of interest."
Pinpoint the Execution: Move to a lower timeframe (e.g., 15-Minute). Use the Adjusted Trade Suggestion and Sentiment Momentum to find a precise entry as momentum begins to shift back in the direction of the primary trend. You can set alerts on the oscillator's zero-line for early warnings of a sentiment shift.
As a Confirmation Tool: If you have an existing trade idea, use the indicator to validate it. Does the sentiment score align with your bullish or bearish thesis? Does the momentum confirm that now is a good time to enter?
As an Idea Generation Tool: Unsure what to trade? Browse different assets and let the indicator's "Primary Trades" and "Adjusted Trade Suggestion" present you with a list of risk-assessed ideas that you can then investigate further.
Disclaimer: This is an analysis tool and should not be considered financial advice. All forms of trading involve substantial risk. You should not trade with money you cannot afford to lose. Always perform your own due diligence and use this indicator as one component of a complete trading plan.
Summary
This all-in-one indicator is designed to be a comprehensive co-pilot for your trading journey. It moves beyond simple buy/sell signals by analyzing the underlying market sentiment and providing a dynamic, risk-assessed guide of potential trading strategies. Whether you're a novice learning the ropes or an expert seeking confirmation, this tool provides a structured framework for making smarter, more informed decisions in stocks, options, and futures.
How It Works
The core of the indicator is the Sentiment Oscillator, which calculates a score from -5 (Extremely Bearish) to +5 (Extremely Bullish) on every bar. This isn't just a single measurement; it's a weighted aggregate of several key technical conditions:
Trend Analysis: Price position relative to the 20, 50, and 200 EMAs.
Momentum Analysis: The current RSI value.
Hybrid Analysis: The state of the MACD and its signal line.
These factors are intelligently combined and normalized to produce a single, intuitive sentiment score, giving you an at-a-glance understanding of the market's pulse.
Core Features
Dynamic Trade Recommendation Table:
The informational heart of the indicator. This on-chart table provides a list of potential trades perfectly aligned with the current sentiment score.
Risk-Ranked Strategies:
All suggested trades are logically ordered by risk, helping you quickly identify strategies that match your comfort level.
Adjusted Trade Suggestions:
The indicator analyzes sentiment momentum (the score vs. its signal line) to provide proactive, forward-looking trade ideas based on where the market might be heading next.
Customizable Trading Styles:
Tell the indicator if you are a Conservative, Neutral, or Aggressive trader, and the "Adjusted Trade Suggestion" will automatically tailor its recommendations to your personal risk preference.
Context-Aware Futures Mode:
When viewing a futures contract, enable this mode to switch all recommendations from stock/options to futures-specific actions (e.g., "Cautious Long," "Monitor Range").
Predictive Sentiment Cone:
Visualize the potential short-term path of sentiment based on current momentum, helping you anticipate future conditions.
Fully Customizable:
Every parameter—from EMA lengths to trade filters—can be adjusted, allowing you to fine-tune the indicator to your exact specifications.
How to Use This Indicator
This tool is flexible and can be integrated into many trading systems. Here is a powerful, professional approach:
Top-Down Analysis (for Swing or Position Trading):
Establish the Trend: Start on the higher timeframes (Monthly, Weekly, Daily). Use the oscillator's color and score to define the dominant, long-term market sentiment. You only want to look for trades that align with this macro trend.
Refine the Entry: Drop down to the medium timeframes (4-Hour, 1-Hour). Wait for the sentiment on these charts to come into alignment with the higher-timeframe trend. This pullback or consolidation is your "zone of interest."
Pinpoint the Execution: Move to a lower timeframe (e.g., 15-Minute). Use the Adjusted Trade Suggestion and Sentiment Momentum to find a precise entry as momentum begins to shift back in the direction of the primary trend. You can set alerts on the oscillator's zero-line for early warnings of a sentiment shift.
As a Confirmation Tool: If you have an existing trade idea, use the indicator to validate it. Does the sentiment score align with your bullish or bearish thesis? Does the momentum confirm that now is a good time to enter?
As an Idea Generation Tool: Unsure what to trade? Browse different assets and let the indicator's "Primary Trades" and "Adjusted Trade Suggestion" present you with a list of risk-assessed ideas that you can then investigate further.
Disclaimer: This is an analysis tool and should not be considered financial advice. All forms of trading involve substantial risk. You should not trade with money you cannot afford to lose. Always perform your own due diligence and use this indicator as one component of a complete trading plan.
Açık kaynak kodlu komut dosyası
Gerçek TradingView ruhuna uygun olarak, bu komut dosyasının oluşturucusu bunu açık kaynaklı hale getirmiştir, böylece yatırımcılar betiğin işlevselliğini inceleyip doğrulayabilir. Yazara saygı! Ücretsiz olarak kullanabilirsiniz, ancak kodu yeniden yayınlamanın Site Kurallarımıza tabi olduğunu unutmayın.
Feragatname
Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, işlem veya diğer türden tavsiye veya tavsiyeler anlamına gelmez ve teşkil etmez. Kullanım Şartları'nda daha fazlasını okuyun.
Açık kaynak kodlu komut dosyası
Gerçek TradingView ruhuna uygun olarak, bu komut dosyasının oluşturucusu bunu açık kaynaklı hale getirmiştir, böylece yatırımcılar betiğin işlevselliğini inceleyip doğrulayabilir. Yazara saygı! Ücretsiz olarak kullanabilirsiniz, ancak kodu yeniden yayınlamanın Site Kurallarımıza tabi olduğunu unutmayın.
Feragatname
Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, işlem veya diğer türden tavsiye veya tavsiyeler anlamına gelmez ve teşkil etmez. Kullanım Şartları'nda daha fazlasını okuyun.