DailyLosers (Function)

image\trumpet2.gif Disclaimer

The DailyLosers function returns the number of losing strategy positions that were taken throughout the date specified by the input TrgtDate.

Syntax

DailyLosers(TargetDate_YYYMMDD)

Returns (Integer)

The number of losing strategy position entries on a date.

Parameters

Name Type Description
TargetDate_YYYMMDD Numeric Sets the target date, entered in the format "YYYMMDD" or a date related function or calculation.

Remarks

The DailyLosers function only works in a Strategy or a called Function within a Strategy, and will not work in any other indicator or analysis technique study type. The function is limited to looking back 10 positions, so the maximum number of DailyLosers that could be reported is 10, if the last ten trades of the target date were losers.

The input parameter TrgtDate can be a constant value such as 1020601 (6-1-2002), where 102 = 2002, 103 = 2003, and so on. It can also reference date related keywords like date, (which returns the current bar date), and CurrentDate, (which returns the data feed date.)

Examples

Assigns to Value1 the number of losing trades throughout each day in the chart:

Value1 = DailyLosers(Date);

Assigns to Value1 the number of losing trades throughout the current day only and checks for three losing trades:

Value1 = DailyLosers(CurrentDate);

if Value1 = 3 then

See Also

DailyWinners