half day stock market

Questions about MultiCharts and user contributed studies.
NiC72
Posts: 111
Joined: 02 Nov 2009
Location: Sweden
Has thanked: 39 times
Been thanked: 14 times

half day stock market

Postby NiC72 » 06 May 2010

I close the long / short every day.
How do I resolve that the stock market closes half days?
(It happens about. 10 times / year) issue of a signal.

Shuld I make a array with dates and then make a check in that array for a early close?
How to close for the day?
(SessionEndTime doesnt seems to work in this case)

User avatar
Anastassia
Posts: 179
Joined: 18 Jan 2010
Been thanked: 4 times

Postby Anastassia » 07 May 2010

Hi NiC72,
Shuld I make a array with dates and then make a check in that array for a early close?
Yes, you should. Please see the code example:

Code: Select all

input: Time_Beg_Close(1550), Time_End_Close(1600);

if time >=Time_Beg_Close and time <= Time_End_Close and date=X then
begin
sell next bar at market;
buy to cover next bar at market;
end;
Thank you


Return to “MultiCharts”