neeed help - strategy position related

Questions about MultiCharts and user contributed studies.
vking
Posts: 235
Joined: 21 May 2009
Has thanked: 51 times
Been thanked: 41 times

neeed help - strategy position related

Postby vking » 07 Oct 2011

Hello - I have few questions related to strategy positions(all questions are inter-related and would help to determine the next course of action for me). Appreciate if someone can give some input on this:

Question 1:
- Is it possible to give a variable name to order name rather than hard-coded string? This would give more flexibility for what I am trying to do.

for example: usual way of coding:
buy ("LE") 1 contract next bar market;

is there any option to change this to
Var: OrderName("LE");
buy (OrderName) 1 contract next bar market;

Question 2:
- Is it possible to determine the queued up orders/limit price(no fill yet - just queued up) for a chart through any of the keywords? Would like to check on the open order name / price so that a separate section can be coded to determine the next set of actions.

Question 3:
- is there any efficient way to find out if the limit price is hit but not filled ( in backtesting - as soon as the price hits - there is a fill but in real world - there is a possibility of not getting filled and would like to handle this condition ). Trying to determine the way to handle this. For single order entry - it's easier to check for the price movement and cancel the order if there is no fill. But for single strategy multiple orders ( few orders could be at the same price ) it would become difficult to determine and handle the no-fill/cancel without the "queued" up ordername/price and answer from question 2 should help in a great deal.

Thanks in advance!!

User avatar
Henry MultiСharts
Posts: 8479
Joined: 25 Aug 2011
Has thanked: 1211 times
Been thanked: 2720 times

Re: neeed help - strategy position related

Postby Henry MultiСharts » 07 Oct 2011

Hello Vking.
1) Order name is a static information, it cannot be changed with script recalculation. That means Q1 is not possible.
2) Unfortunately that is also not possible. If the order price is changed-order will be modified or replaced. THe order price is user specified in the script
3) Order prices are specified in the script. During the price order generation you can store the prices in an array for example and do the same for the names of the price orders.

vking
Posts: 235
Joined: 21 May 2009
Has thanked: 51 times
Been thanked: 41 times

Re: neeed help - strategy position related

Postby vking » 07 Oct 2011

thanks Henry.

For Question 2:
- Is it possible to determine the queued up orders/limit price(no fill yet - just queued up) for a chart through any of the keywords? Would like to check on the open order name / price so that a separate section can be coded to determine the next set of actions.

- How does MC translates the pending order to filled order and map it? Is it possible to get access to that information?
- based on some other thread below:
you were going to provide access to certain information from Accounts tab.

viewtopic.php?f=1&t=8971

Is this something that can be extracted from accounts tab and provide access to power language in terms of "pending/queued" up order names/type and price?

Thanks.
These users thanked the author vking for the post:
JoshM

User avatar
Henry MultiСharts
Posts: 8479
Joined: 25 Aug 2011
Has thanked: 1211 times
Been thanked: 2720 times

Re: neeed help - strategy position related

Postby Henry MultiСharts » 10 Oct 2011

Q2) Unfortunately that is not possible.
The order is transmitted to the broker, MC receives status updates from the broker.
That is not possible to access that information from the PowerLanguage at the moment.
Information from Accounts tab cannot provide access to power language in terms of "pending/queued" up order names/type and price.
To achieve your goal you need to wait for the implementation of your feature request.

vking
Posts: 235
Joined: 21 May 2009
Has thanked: 51 times
Been thanked: 41 times

Re: neeed help - strategy position related

Postby vking » 10 Oct 2011

Thanks Henry. "wait mode" at present until atleast one of my requests gets implemented to help me use advanced order handling through MC :(

Yves BENOIT
Posts: 30
Joined: 17 Jul 2009
Has thanked: 5 times
Been thanked: 10 times

Re: neeed help - strategy position related

Postby Yves BENOIT » 07 Dec 2012

Hello vking,

I posted a request in Project Management about the same issue as your Question 1:
- Is it possible to give a variable name to order name rather than hard-coded string? This would give more flexibility for what I am trying to do.

The request number is MC-1179.
Could you please vote for it, and have other friends concerned by this issue
vote also for it?
Thanks

Yves


Return to “MultiCharts”