Suppose we have the following statement:
buy("Entry 1") 10 contracts next bar at 1000 stop;
After the order is filled at 2 different prices: 1000 and 1001,
what will PosTradeCount(0) return?
Will it be 1 because they are both from "Entry 1"?
Or will it be 2 because they are filled at different prices?
Thanks a lot!
Scott
PosTradeCount with Different Filled Prices [SOLVED]
- TJ
- Posts: 7743
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2222 times
Re: PosTradeCount with Different Filled Prices
I don't have the answer for you.
Does your broker offer a paper trading account?
You should always test your strategy to gain a better understanding of how the codes work.
Does your broker offer a paper trading account?
You should always test your strategy to gain a better understanding of how the codes work.
Re: PosTradeCount with Different Filled Prices
If the paper trading account does not fill an order with varying prices, which is most likely the case,
the situation can not be observed in that way.
the situation can not be observed in that way.
- TJ
- Posts: 7743
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2222 times
Re: PosTradeCount with Different Filled Prices
If the paper trading account does not fill an order with varying prices, which is most likely the case,
the situation can not be observed in that way.
Who is your broker?
What do you mean by " not fill an order with varying prices"?
Re: PosTradeCount with Different Filled Prices
My broker is Interactive Brokers.
For example,
buy("Entry 1") 10 contracts next bar at 1000 stop;
8 contracts are filled at 1000 and the other 2 contracts are filled at 1001.
Thanks!
For example,
buy("Entry 1") 10 contracts next bar at 1000 stop;
8 contracts are filled at 1000 and the other 2 contracts are filled at 1001.
Thanks!
- TJ
- Posts: 7743
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2222 times
Re: PosTradeCount with Different Filled Prices [SOLVED]
My broker is Interactive Brokers.
For example,
buy("Entry 1") 10 contracts next bar at 1000 stop;
8 contracts are filled at 1000 and the other 2 contracts are filled at 1001.
Thanks!
Please use IB's paper trading account to test your trading system.
IB's paper trading account is a 100% copy of your real money account.
ie what you get in the paper account is exactly what you will get in your real money account.
note: use the paper trading account, not the demo account.