Skip to main content
skill CX Codex

risk-reward-ratio — Claude Code skill for trade analysis

The risk-reward-ratio Claude Code skill evaluates trade risk and potential returns after costs. It calculates R multiples, breakeven win rate, and expectancy for entries, stops, and targets.

MIT ★ 69 updated 2026-11-13

Install into Claude Code · Plugin marketplace All methods and platforms ↓
/plugin marketplace add Shubhamkumartrichy/claude-trading-skills-india
/plugin install india-trading-skills@india-trading-skills
Open on GitHub

What risk-reward-ratio does

The skill measures a trade’s risk-to-reward ratio after trading costs. It calculates R for each target, weighted R for partial exits, the breakeven win rate, and trade expectancy. The risk.py rr command includes round-trip charges for Indian trades.

Compare trade ideas, enter a win rate, or set costs with --cost-pct. For options, the assessment factors in premium, time decay, and implied volatility. For short option positions, the skill directs attention to expectancy and tail loss as well as R:R. Python 3 is needed to run ../position-sizing/scripts/risk.py.

The skill also sets minimum R thresholds after costs and checks target and stop assumptions against resistance levels and ATR. Its examples put typical short-option trades around R 0.25–0.5.

What it helps with

  • calculate R:R for an entry, stop, and multiple targets
  • include trading costs in a trade assessment
  • find the win rate needed to break even
  • compare expectancy across trade ideas
  • assess option risk with time decay and implied volatility

Example prompts for the agent

  • Calculate the trade’s R:R after costs: entry 1800, stop 1700, target 2100.
  • Work out weighted R for exits of 50/30/20 at 1900, 2000, and 2200, with a 45% win rate.
  • Compare these option trades, accounting for time decay and implied volatility.

How to install risk-reward-ratio

1Plugin marketplace

/plugin marketplace add Shubhamkumartrichy/claude-trading-skills-india
/plugin install india-trading-skills@india-trading-skills

This installs the whole india-trading-skills plugin with all its skills

2Skills CLI (Vercel)

npx skills add Shubhamkumartrichy/claude-trading-skills-india --skill risk-reward-ratio -a claude-code

3Manually: put the files in place

~/.claude/skills/risk-reward-ratio/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/risk-reward-ratio/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about risk-reward-ratio

How do I install risk-reward-ratio in Claude Code?

Add the marketplace with /plugin marketplace add Shubhamkumartrichy/claude-trading-skills-india, then install the skill with /plugin install india-trading-skills@india-trading-skills.

What does risk-reward-ratio do?

It calculates trade R:R after costs, breakeven win rate, and expectancy. For options, it factors in premium, time decay, and implied volatility.

What does risk-reward-ratio need to run?

The calculation uses Python 3 and ../position-sizing/scripts/risk.py. Option analysis also uses options.py greeks and options.py payoff.

Source text

SKILL.md · MIT
---
name: risk-reward-ratio
description: |
  Risk-reward evaluation for Indian trades after real costs: R multiples per target, weighted R for
  scale-outs, breakeven win rate, expectancy, trade-filter thresholds, and option-specific R:R
  (theta, IV, premium). risk.py rr computes everything including Indian round-trip charges.

  Use when the user asks: "is this trade worth it", "risk reward for entry X stop Y target Z", "R:R",
  "expected value", "what win rate do I need", "should I take this setup", or compares multiple
  trade ideas.
---

# Risk-Reward Ratio

If the maths doesn't work after costs, skip the trade. R:R is the cheapest filter there is.

## Calculator

```bash
python3 ../position-sizing/scripts/risk.py rr --entry 1800 --stop 1700 --target 2100
python3 ../position-sizing/scripts/risk.py rr --entry 1800 --stop 1700 \
    --target 1900:50 --target 2000:30 --target 2200:20 --win-rate 45 --cost-pct 0.25
python3 ../position-sizing/scripts/risk.py rr --entry 450 --stop 470 --target 410 --cost-pct 0.05   # short
```
Weights after `:` are the % of the position exited at each target. `--cost-pct` is the round-trip
cost (delivery ≈0.25, intraday ≈0.05, futures ≈0.06, or exact from `trading-costs`).

## Core maths

```
R per target   = (Target − Entry) ÷ (Entry − Stop)              long; mirror for shorts
R after costs  = (Reward − cost) ÷ (Risk + cost)
Weighted R     = Σ weight × R
Breakeven win% = 1 ÷ (1 + R_after_costs)
Expectancy (R) = W × R_after_costs − (1 − W)
```

Example: entry ₹1,800, stop ₹1,700, scale out 50/30/20 at ₹1,900/₹2,000/₹2,200 gives a weighted
1.90R. With 0.25% delivery costs it is 1.78R, so the breakeven win rate is 36%. At a 45% win rate,
expectancy is +0.25R per trade.

## Minimum R by win rate

| Win rate | Breakeven R | Recommended min R (after costs) |
|---|---|---|
| 30% | 2.33 | 3.0 |
| 40% | 1.50 | 2.0 |
| 50% | 1.00 | 1.5 |
| 60% | 0.67 | 1.0 |

If the user doesn't know their win rate, assume 40–45% and require at least 2R after costs.
`risk.py journal` measures the real win rate from their trades.

## Filter

| R after costs | Decision |
|---|---|
| < 1 | Skip |
| 1 – 1.5 | Only with a proven >55% win rate |
| 1.5 – 2 | Acceptable |
| 2 – 3 | Good (standard swing) |
| > 3 | Excellent, but check the target is realistic (below the next major resistance) |

## Making R honest
- **Target realism:** the target must sit at or before the next real resistance (`ta.py levels`), the
  Fib extension, or the expected move. A target above three resistance levels is fantasy R.
- **Stop realism:** if the stop is inside daily noise (under 1 ATR), the "great R:R" is an illusion of
  a tight stop.
- **Costs and slippage:** small targets in small caps lose a lot to spread and impact.

## Options
- **Long options:** R:R depends on the move **and its timing**. Price the target premium with
  `options.py greeks` at the target date and IV (IV often falls after events: IV crush). A ₹100 → ₹200
  target needs the underlying move before theta eats the premium.
- **Short options:** typical credit trades risk 2–4 units to make 1 (R ≈ 0.25–0.5) with a high win
  rate. Judge them on expectancy and tail loss, not R. `options.py payoff` gives max profit, max loss,
  breakevens and probability of profit.

## Checklist
- [ ] Specific target(s) at real levels
- [ ] Stop at a technical invalidation point, ≥1 ATR away
- [ ] R ≥ 1.5–2 **after costs**
- [ ] Position risk ≤ 1–2% of capital
- [ ] Positive expectancy at a realistic win rate

© Shubham Kumar · MIT · Shubhamkumartrichy/claude-trading-skills-india

Similar skills

SKILL.md skills catalog →

From the same set36

The whole set →
india-trading-skills The india-trading-skills Claude Code plugin analyzes NSE and BSE equities, F&O, trading costs, and Indian taxes. Ask about a stock, options setup, or portfolio to get calculations and market analysis. ★ 69repo stars rsi-divergence The rsi-divergence Claude Code skill detects RSI(14) divergences on NSE/BSE stocks and indices. It activates for questions about bullish or bearish divergence and whether momentum confirms a new high or low. CX Codex +1 ★ 69repo stars trailing-stops A Claude Code skill for calculating trailing stops on NSE/BSE positions. It activates when a trade moves into profit and the stop needs an update. CX Codex +1 ★ 69repo stars fibonacci-trading The fibonacci-trading Claude Code skill calculates Fibonacci retracement zones and extension targets for NSE/BSE stocks and indices. It activates for pullback-entry questions or requests to calculate levels from a swing high and low. CX Codex +1 ★ 69repo stars multi-timeframe-analysis The multi-timeframe-analysis Claude Code skill reads a stock or index across multiple timeframes. It compares the higher-timeframe bias with a daily setup and entry timing on shorter bars. CX Codex +1 ★ 69repo stars stop-loss-strategies The stop-loss-strategies Claude Code skill helps set initial stops for Indian equities and F&O trades. It covers chart levels, position risk, and order execution. CX Codex +1 ★ 69repo stars fundamental-screening The fundamental-screening Claude Code skill screens Indian listed companies for fundamentals and governance risks. It runs on requests to assess a company, review quarterly results, or compare stocks. CX Codex +1 ★ 69repo stars ipo-analysis The ipo-analysis Claude Code skill evaluates Indian mainboard and SME IPOs. It activates for questions about applying, subscription figures, allotment chances, or listing dates. CX Codex +1 ★ 69repo stars

Project sponsors

Companies that keep this analytics open