PROTECTED SOURCE SCRIPT
EPS & Sales - MarketSmith/MarketSurge Style

The EPS & Sales indicator is designed for traders and investors who rely on earnings power and revenue growth as key components of their decision-making process. Inspired by the style and structure of MarketSmith and MarketSurge, this script brings a complete fundamental snapshot directly onto your chart, allowing you to analyze quarterly performance without leaving the TradingView platform. Instead of switching between data sources or relying on disconnected tools, this indicator consolidates multiple layers of information—EPS, sales, estimates, growth rates, surprises, gross margin, ROE, and more—into one integrated visual framework.
At the core of the script is its ability to detect each earnings report by observing changes in TradingView’s earnings data. Once an earnings event is identified, the indicator captures the new EPS and sales values, fetches historical data, and organizes it into a structured quarterly timeline. In doing so, it reconstructs up to eight quarters of earnings and revenue progression, letting you follow a company’s financial trajectory at a glance. The script distinguishes between actual EPS and standardized EPS, intelligently compensating for missing data by back-filling where appropriate. This blended approach results in a data representation closer to the conventions used by IBD/MarketSmith.
One of the signature components of the indicator is its Weekly Earnings Table. This panel displays EPS values, EPS growth both year-over-year and quarter-over-quarter, EPS surprises relative to analysts’ estimates, and revenue figures scaled dynamically into millions or billions. It also includes sales growth rates, sales surprises, and optional rows for gross margin and return on equity. The table is color-formatted using alternating bands for improved readability, and users may choose between a classic bordered table and a more modern “HeadBand” style. Thematic presets allow the display to mimic either the MarketSmith legacy look or the newer MarketSurge aesthetic.
For daily charts, the indicator provides a streamlined HeadBand Table focused on the most recent four quarters. This condensed version shows EPS versus the same quarter a year ago, EPS percentage change, sales and sales growth, and optional ROE or gross margin. It also highlights the next scheduled earnings date, making this tool particularly useful for traders managing risk around upcoming reports.
In addition to the tables, the script can annotate the price chart itself. At each earnings bar, it may draw an arrow or numeric label indicating the EPS percentage change, with the option to include sales percentage change as well. These annotations adopt intuitive color coding, using green for positive numbers and red for negative ones, and they follow the same ±999% cap used by MarketSmith to manage extreme values. Users looking for a cleaner chart can disable the arrow graphics entirely and show only the percentage digits.
The script also includes a series of safeguards to handle the messy realities of earnings data. It mitigates issues caused by irregular reporting schedules, addresses TradingView data gaps, corrects duplicated values, and handles negative EPS figures with an optional “#” prefix indicating calculations based on negative-to-positive transitions. Users may choose to remove this prefix or force the indicator to always display percentage changes even when the company is unprofitable.
Overall, the EPS & Sales indicator is not a trading system but a research and visualization tool. It is built for traders who follow growth-oriented strategies—especially those influenced by CANSLIM or Mark Minervini’s SEPA approach—and who want to see fundamental acceleration alongside price movement. By embedding quarterly financial performance directly into the chart, the script enables faster, more informed analysis and brings the essential components of fundamental evaluation into the heart of technical workflow.
At the core of the script is its ability to detect each earnings report by observing changes in TradingView’s earnings data. Once an earnings event is identified, the indicator captures the new EPS and sales values, fetches historical data, and organizes it into a structured quarterly timeline. In doing so, it reconstructs up to eight quarters of earnings and revenue progression, letting you follow a company’s financial trajectory at a glance. The script distinguishes between actual EPS and standardized EPS, intelligently compensating for missing data by back-filling where appropriate. This blended approach results in a data representation closer to the conventions used by IBD/MarketSmith.
One of the signature components of the indicator is its Weekly Earnings Table. This panel displays EPS values, EPS growth both year-over-year and quarter-over-quarter, EPS surprises relative to analysts’ estimates, and revenue figures scaled dynamically into millions or billions. It also includes sales growth rates, sales surprises, and optional rows for gross margin and return on equity. The table is color-formatted using alternating bands for improved readability, and users may choose between a classic bordered table and a more modern “HeadBand” style. Thematic presets allow the display to mimic either the MarketSmith legacy look or the newer MarketSurge aesthetic.
For daily charts, the indicator provides a streamlined HeadBand Table focused on the most recent four quarters. This condensed version shows EPS versus the same quarter a year ago, EPS percentage change, sales and sales growth, and optional ROE or gross margin. It also highlights the next scheduled earnings date, making this tool particularly useful for traders managing risk around upcoming reports.
In addition to the tables, the script can annotate the price chart itself. At each earnings bar, it may draw an arrow or numeric label indicating the EPS percentage change, with the option to include sales percentage change as well. These annotations adopt intuitive color coding, using green for positive numbers and red for negative ones, and they follow the same ±999% cap used by MarketSmith to manage extreme values. Users looking for a cleaner chart can disable the arrow graphics entirely and show only the percentage digits.
The script also includes a series of safeguards to handle the messy realities of earnings data. It mitigates issues caused by irregular reporting schedules, addresses TradingView data gaps, corrects duplicated values, and handles negative EPS figures with an optional “#” prefix indicating calculations based on negative-to-positive transitions. Users may choose to remove this prefix or force the indicator to always display percentage changes even when the company is unprofitable.
Overall, the EPS & Sales indicator is not a trading system but a research and visualization tool. It is built for traders who follow growth-oriented strategies—especially those influenced by CANSLIM or Mark Minervini’s SEPA approach—and who want to see fundamental acceleration alongside price movement. By embedding quarterly financial performance directly into the chart, the script enables faster, more informed analysis and brings the essential components of fundamental evaluation into the heart of technical workflow.
Script protetto
Questo script è pubblicato come codice protetto. Tuttavia, è possibile utilizzarle liberamente e senza alcuna limitazione – ulteriori informazioni qui.
Declinazione di responsabilità
Le informazioni e le pubblicazioni non sono intese come, e non costituiscono, consulenza o raccomandazioni finanziarie, di investimento, di trading o di altro tipo fornite o approvate da TradingView. Per ulteriori informazioni, consultare i Termini di utilizzo.
Script protetto
Questo script è pubblicato come codice protetto. Tuttavia, è possibile utilizzarle liberamente e senza alcuna limitazione – ulteriori informazioni qui.
Declinazione di responsabilità
Le informazioni e le pubblicazioni non sono intese come, e non costituiscono, consulenza o raccomandazioni finanziarie, di investimento, di trading o di altro tipo fornite o approvate da TradingView. Per ulteriori informazioni, consultare i Termini di utilizzo.