UNPKG

@thuantan2060/technicalindicators

Version:
37 lines (36 loc) 1.43 kB
import StockData from '../StockData'; import CandlestickFinder, { ICandlestickConfig } from './CandlestickFinder'; /** * Configuration interface for TweezerBottom pattern. * Only requires scale parameter since this pattern uses direct price comparisons. */ export interface ITweezerBottomConfig extends ICandlestickConfig { } /** * Default configuration for TweezerBottom pattern. */ export declare const DEFAULT_TWEEZER_BOTTOM_CONFIG: ITweezerBottomConfig; export default class TweezerBottom extends CandlestickFinder { constructor(config?: ITweezerBottomConfig); logic(data: StockData): boolean; downwardTrend(data: StockData): boolean; hasTweezerBottomPattern(data: StockData): boolean; } /** * Detects TweezerBottom candlestick pattern. * * A TweezerBottom is a bullish reversal pattern that occurs at the end of a downtrend. * It consists of two or more candles with approximately equal lows, suggesting * support at that price level. * * @param data - Stock data containing OHLC values * @param config - Configuration options for the pattern detection * @returns True if TweezerBottom pattern is detected, false otherwise * * @example * ```typescript * const data = { open: [...], high: [...], low: [...], close: [...] }; * const isPattern = tweezerbottom(data, { scale: 0.001 }); * ``` */ export declare function tweezerbottom(data: StockData, config?: ITweezerBottomConfig): any;