Dukascopy
 
 
Wiki JStore Search Login

Attention! Read the forum rules carefully before posting a topic.

    Try to find an answer in Wiki before asking a question.
    Submit programming questions in this forum only.
    Off topics are strictly forbidden.

Any topics which do not satisfy these rules will be deleted.

getCloseTime() of parially closed trades returns average close time
 Post subject: getCloseTime() of parially closed trades returns average close time Post rating: 0   New post Posted: Wed 12 Dec, 2012, 18:38 
User avatar

User rating: 7
Joined: Fri 13 Jan, 2012, 20:49
Posts: 94
Location: Poland, Warsaw
Hi Support Team,

I would like to report a problem with IHistory and method getCloseTime() with partially closed orders.

When the method is invoked on IOrder object retrieved from CLOSE_OK message it returns the real close time (close time of last part - which is good).

When the method is invoked on the same order but IOrder object is retrived from IHistory, the method returns something like average time. For example: if you do 4 partial closes on a trade, time returned by getCloseTime() will fall somewhere between first and send close. Such time is pointless, it does not give any info when the partial closes where really executed - I have average time but if I don't have info about devation, how much forward or backward I should go it is useless.

Close time of close of final part of an order is not perfect but at least gives a concrete information.

Can you please make the method coherent regadless of source of IOrder object?

thanks and best regards,
kurak


 
 Post subject: Re: getCloseTime() of parially closed trades returns average close time Post rating: 0   New post Posted: Fri 11 Jan, 2013, 21:59 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
The returned close time was not average, rather the close time of a random partial close. After the fix the position's close time always is the close time of the last partial close.


 

Jump to:  

  © 1998-2025 Dukascopy® Bank SA
On-line Currency forex trading with Swiss Forex Broker - ECN Forex Brokerage,
Managed Forex Accounts, introducing forex brokers, Currency Forex Data Feed and News
Currency Forex Trading Platform provided on-line by Dukascopy.com