Login Page - Create Account

Support Board


Date/Time: Sun, 22 Dec 2024 11:51:33 +0000



[User Discussion] - Exit at certain time

View Count: 1105

[2015-02-11 21:45:11]
User73713 - Posts: 5
Hello,
how is formula for Exiting a position at a certain time,
example: entry is at 16:00 and I want at 17:00 exit,
thank you.
[2015-02-11 21:55:01]
Sawtooth - Posts: 4141
This will go TRUE at 17:00, and stay TRUE for 5 seconds:
=AND($J$41>TIMEVALUE("16:59:59"),$J$41<TIMEVALUE("17:00:05"))

This will go TRUE one hour after entry, and stay TRUE for 5 seconds:
=AND($J$41-$J$42>TIMEVALUE("00:59:59"),$J$41-$J$42<TIMEVALUE("01:00:05"))



Date Time Of Last Edit: 2015-02-11 23:04:59
[2015-02-12 21:44:26]
User73713 - Posts: 5
Thank you for your answer,
but I do not know how the formula used to backtest.
In column K (M) are formulas for entries and in column A "Date Time"
What is the formula for column L (N) to exit +1 hour from entry.
[2015-02-12 22:47:04]
Sawtooth - Posts: 4141
Try this:
L3:
=AND($J$8>0,$J$41-$J$42>TIMEVALUE("00:59:59"),$J$41-$J$42<TIMEVALUE("01:00:05"))
N3:
=AND($J$8<0,$J$41-$J$42>TIMEVALUE("00:59:59"),$J$41-$J$42<TIMEVALUE("01:00:05"))

Column A is the bar open time.
J41 is the chart update time; it is updated much more frequently.
J42 is the time of the most recent entry.
[2015-02-12 23:41:59]
User73713 - Posts: 5
Thank you much,
it's OK.

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account