Conversion to Multicharts.net needed

Questions about MultiCharts .NET and user contributed studies.
frugalmule
Posts: 11
Joined: 12 Mar 2014

Conversion to Multicharts.net needed

Postby frugalmule » 17 Feb 2017

Conversion to Multicharts.net needed.

How do I convert the following?

Code: Select all

Vars:
   double TradeSize(1),
   IntrabarPersist bool Filter(true), //used just before sending order
   IntrabarPersist double PriceBuyMarket(0), //order open price
   IntrabarPersist double PriceSellMarket(0); //order open price

//Close Long Positions
if XAverageOrig(Close, 10) of Data2 < XAverage(Close, 30) of Data2 //Exponential Moving Average Original < Exponential Moving Average
then
begin
   Filter = (MarketPosition <> 0);   
   if Filter then
      //Sell ("exit2") next bar at Market;
      Sell ("exit2") next bar at .5 * ( CurrentBid + CurrentAsk ) Limit ;
end;

//Open Buy Order
if XAverageOrig(Close, 10) of Data2 > XAverage(Close, 30) of Data2 //Exponential Moving Average Original > Exponential Moving Average
then
begin
   Filter = true;   
   if Filter then
   begin
      PriceBuyMarket = Close;
      //Buy ("entry1") TradeSize contracts next bar at Market;
      Buy ("entry1") TradeSize contracts next bar at .5 * ( CurrentBid + CurrentAsk ) Limit ; // per DougM, The strategy engine will round to a tradeable price.
   end;
end;

//This strategy is intended to use the price of the underlying of Data2 to find the signal, then trade on the option price of Data1.

User avatar
Henry MultiСharts
Posts: 8511
Joined: 25 Aug 2011
Has thanked: 1213 times
Been thanked: 2733 times

Re: Conversion to Multicharts.net needed

Postby Henry MultiСharts » 22 Feb 2017

Hello frugalmule,

Please contact us directly if you are interested in a custom programming project.

frugalmule
Posts: 11
Joined: 12 Mar 2014

Re: Conversion to Multicharts.net needed

Postby frugalmule » 22 Feb 2017

I have to get multicharts to function first and thus far it still doesn't, despite support request over 48 hours old.


Return to “MultiCharts .NET”