★ ★ ★LIVE97 COINS ANALYZED BY CLAUDE MCP·VIEW SKILLS →★ ★ ★
MCP
claude.analyze("BTCUSDT")→ [buy] signal detectedmcp.draw_levels(resistance=98000)→ [drawn] on chartclaude.scan_watchlist(coins=100)→ [42] buy signals foundmcp.connect("tradingview")→ [connected] daily TFclaude.detect_sr("SOLUSDT")→ [S: $165] [R: $185]claude.analyze("ETHUSDT")→ [neutral] consolidatingmcp.screenshot_chart("BNBUSDT")→ [captured] analyzing...claude.score_quality("XRPUSDT")→ score: 78/100mcp.set_timeframe("1D")→ [ok] chart updatedclaude.analyze("BTCUSDT")→ [buy] signal detectedmcp.draw_levels(resistance=98000)→ [drawn] on chartclaude.scan_watchlist(coins=100)→ [42] buy signals foundmcp.connect("tradingview")→ [connected] daily TFclaude.detect_sr("SOLUSDT")→ [S: $165] [R: $185]claude.analyze("ETHUSDT")→ [neutral] consolidatingmcp.screenshot_chart("BNBUSDT")→ [captured] analyzing...claude.score_quality("XRPUSDT")→ score: 78/100mcp.set_timeframe("1D")→ [ok] chart updated
BACK TO CLAUDE SKILLS

normalize_price_data

Data PipelineDataUtils
INSTALLATION
$python -c "exec(open('normalize_price_data.py').read())"
#or paste directly into your Claude Code terminal
[ ABOUT ]

Validates that all required OHLCV keys are present in the input dictionary and converts all values to Python floats, which handles string-typed numbers that some APIs return. Raises `ValueError` immediately on missing keys rather than allowing downstream indicator functions to fail with uninformative index errors.

This function is designed as a pipeline boundary validator — it should be called at the point where external API data enters the local processing pipeline. Normalization ensures consistent numeric types across all downstream calculations, preventing subtle bugs that arise when mixing Python int, float, and string representations of the same price value.

[ USAGE EXAMPLE ]
example.py
raw = {"open": ["100.5", "102"], "high": ["103"], "low": ["99"], "close": ["101"]}
clean = normalize_ohlcv(raw)
# clean["close"] → [101.0]  (float, not string)
[ FULL CODE ]
normalize_price_data.py
def normalize_ohlcv(raw: dict) -> dict: for key in ["open","high","low","close"]: if key not in raw: raise ValueError(f"Missing: {key}") raw[key] = [float(x) for x in raw[key]] return raw
[ METADATA ]
CategoryData Pipeline
ComplexityIntermediate
LanguagePython 3.10+
TagsData, Utils
[ ASK CLAUDE ]

Ask AI about this skill before installing it.

[ RELATED SKILLS ]