Skip to content

Two Crows

Two Crows is a bearish reversal pattern consisting of three candlesticks, signaling a potential trend reversal.

Method

tm.ta.cdl2crows(source_open, source_high, source_low, source_close)

Inputs

ParameterArgument typeDescriptionDefault Value
source_openpd.SeriesOpen prices series-
source_highpd.SeriesHigh prices series-
source_lowpd.SeriesLow prices series-
source_closepd.SeriesClose prices series-

Outputs

OutputType
cdl2crowsnp.ndarray

Example usage

strategy.py
import tradomate as tm
@tm.strategy()
def my_strategy(config: tm.TradomateConfig, data: tm.TradomateData):
# Trying out Two Crows
cdl2crows = tm.ta.cdl2crows(data.open, data.high, data.low, data.close)
# Get the last value and print
last_value = cdl2crows.iloc[-1]
tm.log(f"Last value of Two Crows is {last_value}")
# Plot the values of cdl2crows
tm.plot(cdl2crows, title="Two Crows", overlay=False)