NFI_v5 Strategy Analysis
Strategy Number: #251 (251st of 465 strategies) Strategy Type: NFI Series Standard Version — Multi-Condition Trend Following Timeframe: 5 Minutes (5m) + 1 Hour Informational Timeframe
I. Strategy Overview
NFI_v5 is one of the standard versions of the NFI (Nostalgia For Infinity) series, continuously iterated by developer iterativ based on the classic Nostalgia strategy. As the fifth version of the NFI V series, v5 builds on the predecessor's multi-condition architecture with comprehensive parameter optimization and indicator refinement, representing the mature form of the NFI standard series.
The v5 version is positioned at the "balance point between stability and efficiency" — neither as conservative as early versions nor as complex as the ProAI series. Using the classic 5-minute timeframe, it integrates 20+ independent entry conditions with multi-tiered exit logic and comprehensive risk protection mechanisms. It is suitable for advanced traders pursuing stable returns.
Core Features
| Feature | Description |
|---|---|
| Entry Conditions | 20+ independent buy signals, each independently enableable/disableable |
| Exit Conditions | 8 basic exit signals + multi-layer dynamic take-profit logic |
| Protection Mechanisms | 20+ sets of entry protection parameters (EMA/SMA/safe dips/safe pumps) |
| Timeframe | 5-minute primary timeframe + 1-hour informational timeframe |
| Dependencies | TA-Lib, technical, qtpylib, pandas, numpy |
II. Strategy Configuration Analysis
2.1 Basic Risk Parameters
# ROI exit table (time: minimum profit rate)
minimal_roi = {
"0": 0.08, # Immediate exit: 8% profit
"40": 0.05, # After 40 minutes: 5% profit
"80": 0.03, # After 80 minutes: 3% profit
"120": 0.01 # After 120 minutes: 1% profit
}
# Stop-loss settings
stoploss = -0.12 # -12% hard stop-loss
# Trailing stop
trailing_stop = True
trailing_only_offset_is_reached = True
trailing_stop_positive = 0.02 # 2% trailing activation point
trailing_stop_positive_offset = 0.035 # 3.5% offset trigger
Design Philosophy:
- Steady ROI ladder: First-tier ROI at 8%, slightly more conservative than the original Nostalgia (10%), suitable for stability-seeking traders
- Loose stop-loss buffer: -12% hard stop-loss gives the market sufficient volatility room, avoiding frequent stop-outs
- Gentle trailing stop: 2% activation, 3.5% lock-in, balancing profit protection and trend following
2.2 Order Type Configuration
order_types = {
"entry": "limit", # Limit order entry
"exit": "limit", # Limit order exit
"stoploss": "limit", # Limit stop-loss order
"stoploss_on_exchange": False,
"exit_timeout_count": 0,
}
III. Entry Conditions Details
3.1 Protection Mechanisms (20+ Sets)
Each entry condition has independent protection parameter sets, forming a multi-layered safety net:
| Protection Type | Parameter Description | Function Description | Default Example |
|---|---|---|---|
| EMA Fast | Whether fast EMA is above EMA200 | Trend confirmation | ema_fast_len=26 |
| EMA Slow | Whether 1h slow EMA is above EMA200 | Macro-cycle trend | ema_slow_len=100 |
| Close Price Protection | Whether close price is above EMA | Price position confirmation | close_above_ema_fast_len=200 |
| SMA200 Rising | Whether SMA200 is in uptrend | Long-term trend confirmation | sma200_rising_val=28 |
| Safe Dips | Downward magnitude threshold protection | Prevents bottom-fishing at mid-slope | safe_dips_type=80 |
| Safe Pumps | Upward magnitude threshold protection | Prevents chasing highs | safe_pump_type=70 |
| BTC Trend | Whether BTC 1h is non-declining | Market correlation protection | btc_1h_not_downtrend |
3.2 Typical Entry Condition Examples
Condition #1: RSI Oversold + MFI Low Value
# Logic
- RSI(1h) between 30-84 (macro-cycle not extreme)
- RSI(14) < 36 (oversold zone)
- MFI < 44 (low money flow)
- Price has minimum rise from 36-period low (excludes crash)
Condition #2: Bollinger Lower Band Breakout
# Logic
- RSI < RSI(1h) - 39 (relatively weak)
- MFI < 49 (low money flow)
- Close < Bollinger lower band × 0.983 (deep Bollinger break)
Condition #3: EMA Golden Cross + Bollinger Support
# Logic
- EMA26 > EMA12 (short-term golden cross)
- EMA difference > open price × coefficient (golden cross strength confirmation)
- Close < Bollinger lower band × offset coefficient (price position)
Condition #4: SMA Offset Strategy
# Logic
- Close < SMA × offset coefficient (price relative to moving average position)
- Volume confirmation
- RSI oversold confirmation
3.3 20+ Entry Conditions Classification
| Condition Group | Condition Numbers | Core Logic | Applicable Scenario |
|---|---|---|---|
| Oversold Rebound | 1, 7, 8, 18, 20 | RSI/MFI low value + oversold signals | Oversold bounce |
| Bollinger Strategy | 2, 3, 4, 5, 6, 9, 10 | Price breaks Bollinger lower band | Volatility breakout |
| EMA Trend | 5, 6, 7, 14, 15 | EMA golden cross + price position | Trend confirmation |
| SMA Offset | 9, 10, 11, 12, 13 | Price below SMA by specific ratio | Mean reversion |
| EWO Momentum | 12, 13, 16, 17 | Elliott Wave Oscillator | Momentum confirmation |
| Special Conditions | 19, 21, 22, 23 | Composite indicator strategies | Comprehensive signals |
IV. Exit Conditions Details
4.1 Multi-Layer Take-Profit System
The strategy uses a tiered take-profit mechanism, dynamically adjusting exit conditions based on profit rate:
Profit Rate Zone RSI Threshold Signal Name
────────────────────────────────────────────────────────
> 18% < 32 signal_profit_10
14%-18% < 40 signal_profit_9
10%-14% < 50 signal_profit_8
8%-10% < 52 signal_profit_7
6%-8% < 48 signal_profit_6
5%-6% < 42 signal_profit_5
4%-5% < 40 signal_profit_4
3%-4% < 38 signal_profit_3
2%-3% < 36 signal_profit_2
1%-2% < 34 signal_profit_1
< 1% < 32 signal_profit_0
Design Principles:
- Higher profit = lower RSI threshold (stricter exit conditions)
- Prevents greed, locks in profits promptly
- Dynamically adjusts based on market momentum
4.2 Special Exit Scenarios
| Scenario | Trigger Condition | Signal Name | Description |
|---|---|---|---|
| Below EMA200 take-profit | Price < EMA200 + profit threshold met | signal_profit_u_* | Weak take-profit |
| Pump protection | 24h/36h/48h rise detection + profit | signal_profit_p_* | Prevents high pullback |
| Declining trend | SMA200 declining + profit zone | signal_profit_d_* | Trend reversal protection |
| Trailing take-profit | Max profit drawdown + RSI zone | signal_profit_t_* | Dynamic profit locking |
| Holding duration | Held > 900 minutes + profit | signal_profit_l_1 | Time stop |
4.3 Basic Exit Signals
# Exit Signal 1: Bollinger upper band consecutive breakout
- RSI > 78
- Close > BB20 upper band (4 consecutive candles)
# Exit Signal 2: Short-term overbought
- RSI > 80
- Close > BB20 upper band (2 consecutive candles)
# Exit Signal 3: Dual RSI overbought
- RSI > 72
- RSI(1h) > 78
# Exit Signal 4: Below EMA200 overbought
- Close < EMA200
- Close > EMA50
- RSI > 77
# Exit Signal 5: 1h RSI extreme + EMA death cross
- RSI(1h) > 80
- EMA12 crosses below EMA26
V. Technical Indicator System
5.1 Core Indicators
| Indicator Category | Specific Indicators | Purpose | Parameter Range |
|---|---|---|---|
| Trend Indicators | EMA(12,15,20,25,26,35,50,100,200) | Trend judgment, protection | Multi-period |
| Moving Average | SMA(50,100,200) | Long-term trend confirmation | Medium-long period |
| Momentum | RSI(4,14,20), MFI(14), EWO | Overbought/oversold, momentum strength | Standard |
| Volatility | Bollinger Bands(20,2), BB(40,2) | Price boundaries, breakout signals | Dual-period |
| Volume | CMF(20), OBV | Money flow in/out | Standard |
| Special Indicators | Williams %R(480), StochRSI(96) | Extreme market identification | Long-period |
5.2 Informational Timeframe Indicators (1h)
The strategy uses 1-hour timeframe as the informational layer for higher-dimensional trend judgment:
- EMA/SMA trend confirmation: Macro-cycle moving average direction
- RSI overbought/oversold: 1h-level momentum state
- Pump/crash protection: 24h/36h/48h price change detection
- BTC trend correlation: Impact of macro market on altcoins
5.3 Custom Indicators
| Indicator Name | Calculation Method | Purpose |
|---|---|---|
| TSI | True Strength Index | Smooth momentum |
| Hull(75) | Hull Moving Average | Reduced lag |
| Zema(61) | Zero-lag EMA | Fast response |
| Zlema(68) | Zero-lag Linear EMA | Trend confirmation |
VI. Risk Management Features
6.1 Dip Protection (Safe Dips)
11 levels of dip threshold protection, from strict to loose:
Level Threshold 1 Threshold 2 Threshold 3 Threshold 4
────────────────────────────────────────────────────────────────
10 1.5% 10% 24% 42%
50 2.0% 14% 32% 50%
80 2.4% 22% 38% 66%
100 2.6% 24% 42% 80%
110 2.7% 26% 44% 84%
6.2 Pump Protection (Safe Pump)
12 levels of pump detection to prevent chasing:
- Detection periods: 24h / 36h / 48h
- Threshold range: 0.42 - 2.0 (42% - 200% rise)
- Pullback threshold: 1.4 - 3.0
6.3 BTC Trend Protection
# BTC 1h trend detection
if BTC_1h_downtrend:
# Most buy signals prohibited
# Only extreme oversold signals may trigger
6.4 Hold Trades Support
Supports external config file hold-trades.json for specific pairs to hold to target profit:
{
"profit_ratio": 0.005,
"trade_ids": [123, 456]
}
VII. Strategy Pros & Cons
✅ Pros
- Highly configurable: 20+ independently enableable entry conditions, adaptable to different market environments
- Multi-layer protection: 20+ protection parameter sets + 11-level dip protection + 12-level pump protection
- Dynamic take-profit: RSI-based dynamic exit adjustment based on profit rate, balancing profit and risk
- Multi-timeframe: 5m execution + 1h trend confirmation + BTC correlation analysis
- Classic indicator combinations: Integrates Bollinger Bands, RSI, EMA, EWO and other time-tested indicators
- Mature and stable: v5 is a mature, iteratively optimized version of the NFI series
- Community verified: Long-term live trading verification, issues fully exposed and fixed
⚠️ Cons
- High complexity: Many parameters, optimization and debugging require experience
- Data dependent: Needs sufficient 1h and 5m historical data
- External dependencies: Requires TA-Lib and technical library support
- Overfitting risk: Multi-condition may lead to overfitting historical data
- Computationally intensive: Each cycle calculates many indicators, demanding on performance
- Learning curve: Newcomers need time to understand each parameter's meaning
VIII. Summary
NFI_v5 is the mature standard version of the NFI series. Its core value lies in:
- Modular design: 20+ entry conditions function as independent strategies, flexibly combinable based on market state
- Risk priority: Multi-layer protection ensures capital safety in extreme conditions
- Classic heritage: Integrates decades of validated technical analysis indicators
- Mature and stable: Through multiple iterations, a reliable version of the NFI series
For quantitative traders, NFI_v5 is a choice balancing stability and efficiency:
- More mature and complete than early versions
- Simpler and lower resource consumption than ProAI series
- Suitable as a main strategy for traders with some quantitative foundation
Recommendation:
- Backtest verify with default configuration first
- Adjust protection parameters based on target pair characteristics
- Pay attention to 1h timeframe trend confirmation signals
- Regularly evaluate each entry condition's contribution, optimize the combination