Login Page - Create Account

Support Board


Date/Time: Mon, 23 Dec 2024 00:13:36 +0000



s_SCPositionData Version 1254 SIM-Mode, Replay Mode, LiveMode

View Count: 931

[2015-05-20 14:24:22]
sbsierra - Posts: 71
Dear Supporters,

I currently use s_SCPositionData for getting MaximumOpenPositionProfit and MaximumOpenPositionLoss.
In SIM and REPLAY Mode I get correct values, but with LiveMode on CTS-T4 I get wrong values.

###
Chart: GC.20150600.CME_CO [CV] 5 Min #2 | Study: ALGOCHART | ProfitDebug 1091069.98 MaximumOpenPositionLoss -1088669.98 CurrentStop1 1209.20 | 2015-05-20 16:19:46
Chart: GC.20150600.CME_CO [CV] 5 Min #2 | Study: ALGOCHART | ProfitDebug 1091069.98 MaximumOpenPositionLoss -1088669.98 CurrentStop1 1209.20 | 2015-05-20 16:19:47
Chart: GC.20150600.CME_CO [CV] 5 Min #2 | Study: ALGOCHART | ProfitDebug 1091069.98 MaximumOpenPositionLoss -1088669.98 CurrentStop1 1209.20 | 2015-05-20 16:19:47
Chart: GC.20150600.CME_CO [CV] 5 Min #2 | Study: ALGOCHART | ProfitDebug 1091069.98 MaximumOpenPositionLoss -1088669.98 CurrentStop1 1209.20 | 2015-05-20 16:19:48
Chart: GC.20150600.CME_CO [CV] 5 Min #2 | Study: ALGOCHART | ProfitDebug 1091069.98 MaximumOpenPositionLoss -1088669.98 CurrentStop1 1209.20 | 2015-05-20 16:19:48
Chart: GC.20150600.CME_CO [CV] 5 Min #2 | Study: ALGOCHART | ProfitDebug 1091069.98 MaximumOpenPositionLoss -1088669.98 CurrentStop1 1209.20 | 2015-05-20 16:19:49
Chart: GC.20150600.CME_CO [CV] 5 Min #2 | Study: ALGOCHART | ProfitDebug 1091069.98 MaximumOpenPositionLoss -1088669.98 CurrentStop1 1209.20 | 2015-05-20 16:19:49

###

It should be something like 100 til 200 USD in this log.

Please tell me if you need more information!

Regards,

bs.trader
[2015-05-20 16:44:41]
Sierra Chart Engineering - Posts: 104368
Look at the data of the Trade Statistics tab. Here are instructions:
https://www.sierrachart.com/index.php?l=doc/doc_TradeActivityLog.php#TradeStatisticsTab

Are the Highest Price During Positions and Lowest Price During Positions correct? If not, what are those values and what is the symbol?
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service:
Sierra Chart Teton Futures Order Routing
[2015-05-20 19:07:56]
sbsierra - Posts: 71
The values are correct in the TradeStatistics Tab.
Symbol is GC (Gold Future, CTS-T4)

I use the following code for my Logfile as shown above:

###
s_SCPositionData PositionDataAfterEntries;

double MaximumOpenPositionProfit = -1.00;
double MaximumOpenPositionLoss = -1.00;

MaximumOpenPositionProfit = PositionDataAfterEntries.MaximumOpenPositionProfit;
MaximumOpenPositionLoss = PositionDataAfterEntries.MaximumOpenPositionLoss;

SCString ProfitDebug;
ProfitDebug.Format("ProfitDebug %.2f MaximumOpenPositionLoss %.2f CurrentStop1 %.2f",
    MaximumOpenPositionProfit, MaximumOpenPositionLoss, CurrentStop1 );
sc.AddMessageToLog(ProfitDebug, 0);
###

CurrentStop ist correct, which is done via "s_SCTradeOrder CurrentOrder;"
[2015-05-21 19:01:56]
Sierra Chart Engineering - Posts: 104368
We need to test this. But it will take a little time to get this set up.
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service:
Sierra Chart Teton Futures Order Routing
[2015-05-21 19:11:54]
Sierra Chart Engineering - Posts: 104368
We have determined the source of the problem. This will be solved in the next release.
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service:
Sierra Chart Teton Futures Order Routing

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account