OPEN-SOURCE SCRIPT
Expectancy Reality Check

Most trading discussions focus on entries.
This tool focuses on math.
Expectancy Reality Check is a symbol-agnostic calculator that shows whether your assumed edge is mathematically viable — before you trade it.
It does not generate signals.
It does not predict price.
It exists to answer one question:
“If my assumptions are correct, does this strategy deserve capital?”
What this tool does
Given your assumptions for:
Win rate
Reward-to-Risk (R)
Costs per trade
Risk per trade
Trade frequency
the indicator computes:
Expected Value (R per trade)
Expected Value per month
Break-even win rate (cost-adjusted)
Edge vs break-even (percentage points)
Risk-of-ruin proxy (fixed-fractional approximation)
Estimated sample size needed to validate your win rate at a chosen confidence level
All values are expressed in R-units, not currency, to remain portfolio-independent.
How to use it
Enter honest assumptions — not best-case backtest results.
Observe:
Is EV meaningfully positive?
How small is the margin above break-even?
How many trades are required before results are statistically meaningful?
Decide whether the strategy is worth:
testing,
refining,
or discarding.
If the math fails here, execution quality will not save it.
What this tool is not
❌ Not a strategy
❌ Not a signal generator
❌ Not a performance backtest
❌ Not a guarantee of results
It is a reality check, not a promise.
Notes on methodology
Expectancy is computed in standard R-unit form.
Break-even win rate is adjusted for per-trade costs.
Risk-of-ruin is a proxy, based on a Lundberg-type root for i.i.d. outcomes under fixed fractional risk.
Sample size guidance uses a normal approximation for binomial confidence intervals.
All calculations assume stationarity — real markets may violate this.
Use judgment.
Who this is for
Traders designing rule-based systems
Traders comparing multiple strategies
Traders tired of “high win rate” marketing
Anyone who wants math before emotion
Final note
A strategy with:
high win rate but negative expectancy
or positive expectancy but no statistical margin
is not an edge — it’s noise.
Systems over feelings.
This tool focuses on math.
Expectancy Reality Check is a symbol-agnostic calculator that shows whether your assumed edge is mathematically viable — before you trade it.
It does not generate signals.
It does not predict price.
It exists to answer one question:
“If my assumptions are correct, does this strategy deserve capital?”
What this tool does
Given your assumptions for:
Win rate
Reward-to-Risk (R)
Costs per trade
Risk per trade
Trade frequency
the indicator computes:
Expected Value (R per trade)
Expected Value per month
Break-even win rate (cost-adjusted)
Edge vs break-even (percentage points)
Risk-of-ruin proxy (fixed-fractional approximation)
Estimated sample size needed to validate your win rate at a chosen confidence level
All values are expressed in R-units, not currency, to remain portfolio-independent.
How to use it
Enter honest assumptions — not best-case backtest results.
Observe:
Is EV meaningfully positive?
How small is the margin above break-even?
How many trades are required before results are statistically meaningful?
Decide whether the strategy is worth:
testing,
refining,
or discarding.
If the math fails here, execution quality will not save it.
What this tool is not
❌ Not a strategy
❌ Not a signal generator
❌ Not a performance backtest
❌ Not a guarantee of results
It is a reality check, not a promise.
Notes on methodology
Expectancy is computed in standard R-unit form.
Break-even win rate is adjusted for per-trade costs.
Risk-of-ruin is a proxy, based on a Lundberg-type root for i.i.d. outcomes under fixed fractional risk.
Sample size guidance uses a normal approximation for binomial confidence intervals.
All calculations assume stationarity — real markets may violate this.
Use judgment.
Who this is for
Traders designing rule-based systems
Traders comparing multiple strategies
Traders tired of “high win rate” marketing
Anyone who wants math before emotion
Final note
A strategy with:
high win rate but negative expectancy
or positive expectancy but no statistical margin
is not an edge — it’s noise.
Systems over feelings.
סקריפט קוד פתוח
ברוח האמיתית של TradingView, יוצר הסקריפט הזה הפך אותו לקוד פתוח, כך שסוחרים יוכלו לעיין בו ולאמת את פעולתו. כל הכבוד למחבר! אמנם ניתן להשתמש בו בחינם, אך זכור כי פרסום חוזר של הקוד כפוף ל־כללי הבית שלנו.
כתב ויתור
המידע והפרסומים אינם מיועדים להיות, ואינם מהווים, ייעוץ או המלצה פיננסית, השקעתית, מסחרית או מכל סוג אחר המסופקת או מאושרת על ידי TradingView. קרא עוד ב־תנאי השימוש.
סקריפט קוד פתוח
ברוח האמיתית של TradingView, יוצר הסקריפט הזה הפך אותו לקוד פתוח, כך שסוחרים יוכלו לעיין בו ולאמת את פעולתו. כל הכבוד למחבר! אמנם ניתן להשתמש בו בחינם, אך זכור כי פרסום חוזר של הקוד כפוף ל־כללי הבית שלנו.
כתב ויתור
המידע והפרסומים אינם מיועדים להיות, ואינם מהווים, ייעוץ או המלצה פיננסית, השקעתית, מסחרית או מכל סוג אחר המסופקת או מאושרת על ידי TradingView. קרא עוד ב־תנאי השימוש.