Support Board
Date/Time: Mon, 23 Dec 2024 02:32:37 +0000
Post From: Exiting Trade Automatically Before the Close
[2015-01-12 14:05:47] |
infpz - Posts: 826 |
My question is in regards to setting up an "exit on close" parameter for orders being created while autotrading using the Excel spreadsheet study. First I have my charts set to market hours for the markets being traded (ie 9:30-16:00) A.) I am using the Time Range Highlight study to attempt to accomplish an exit on close. The settings I use on the study are "start time: 16:00 / end time: 9:30 / display forward projection: no". B.) I will reference the TRH study for both entry and exit parameters including it in an AND function with the logic being for ENTRY: TRH=0 and EXIT: TRH>0 as the study registers a 0 when the Highlight condition is negative and a larger than zero number when the condition is true. I believe I have the logic correct however I still get "overnight holds" (i.e. exit at 9:30am the next day) when backtesting. Any thoughts or suggestions are appreciated. |