cdl_pattern#
API documentation for pandas_ta.candles.cdl_pattern Python function.
- cdl_pattern(open_, high, low, close, name='all', scalar=None, offset=None, **kwargs)[source]#
Candle Pattern
A wrapper around all candle patterns.
Examples:
Get all candle patterns (This is the default behaviour) >>> df = df.ta.cdl_pattern(name=”all”) Or >>> df.ta.cdl(“all”, append=True) # = df.ta.cdl_pattern(“all”, append=True)
Get only one pattern >>> df = df.ta.cdl_pattern(name=”doji”) Or >>> df.ta.cdl(“doji”, append=True)
Get some patterns >>> df = df.ta.cdl_pattern(name=[“doji”, “inside”]) Or >>> df.ta.cdl([“doji”, “inside”], append=True)
- Args:
open_ (pd.Series): Series of ‘open’s high (pd.Series): Series of ‘high’s low (pd.Series): Series of ‘low’s close (pd.Series): Series of ‘close’s name: (Union[str, Sequence[str]]): name of the patterns scalar (float): How much to magnify. Default: 100 offset (int): How many periods to offset the result. Default: 0
- Kwargs:
fillna (value, optional): pd.DataFrame.fillna(value) fill_method (value, optional): Type of fill method
- Returns:
pd.DataFrame: one column for each pattern.