what are your thoughts on this?

https://fxgears.com/index.php?threads/python-development-environment-jacks-technology-stack.1090/

QuoteMy primary language is Python. Despite some uninformed beliefs that Python is too slow for algo trading, and that algorithmic trading is best left to C/C++ or some hardware programmed FPGAs, Python is perfectly suitable and more than fast enough for any retail trader who wants to get into algorithmic trading.Despite what some believe, you don't need very beefy hardware to trade or algo trade. A few of my best and most profitable trades have been done on an old netbook with a 10", low resolution, screen. People who invest into expensive hardware, computer setups, etc.. before they even have a prof of concept hammered out (be it a trade plan, or algo strategy,) are putting the 'cart before the horse.'Algos are good for when you don’t have enough hands, eyes, or aren’t fast enough to do something manually. If you already can do something efficiently on your own, then turning it into an algo will only make performance worse because I can’t encapsulate your years of experience into lines of code. Also, if you ask me to code up a moving average crossover strategy, we aren’t friends anymore.

guy writes an algo platform from scratch in python and connects it to multiple brokers and data sources nutz

]]>What do you think? What are the pros and cons coding a robot with MQL4 and Python? I found easier to code with MQL4.. am I wrong?

Kindest,

Mirko

]]>

I am a beginner in EL...

Is there a free code to draw lignes of the retracements on the right side of the charts when PivotHighVSBar found a new pivot like in the link below?

https://www.tradestation.com/Discussions/Topic.aspx?Topic_ID=8864

]]>reading here and there posts in the forum, from coding forum to trading indicators to array ecc... I've never found a code about Volume Profile.

Many codes about Market Profile (TPO) , market delta and something about Peak of Volume at Price (PVP) which is called "mode" in statistic language, but nothing about a good Volume profile accurate to the tick.

I've read posts from TAMS about ARRAY (very good and useful), code from DBantina about PVP (MODE) using tick chart, which could be a very good beginning, but nothing again about the Volume profile, so I've decided to create a new one searching someone who could help me.

This is my start and my steps:

(1)

I've a **GKMarketProfileTL** (see txt attached files) which uses trend lines, but it's a proxy and not accurate to the tick because it uses minutes chart (1 minute chart in the best way).

This indicator is not so useful because with trendlines, it's difficult to plot a volume profile for each day. Trend lines could be useful to plot a single Volume profile for the last day or for a cumulative profile made of more than one day. Then it's not so accurate (not to the tick ).

(2)

I've a second indicator which plots TPO MarketProfile (see txt attached below with its functions) which uses ASCII scripts as I'd like, but it calculates TPO and not Volume Profile. I've modified it to plot NOT only letters (put in inputs letters = false), but even ASCII scripts like "---".

The problem with this indicator is that it's very difficult to decode and modify for my experience. Maybe its functions are useful to plot ascii scripts instead of Trendlines.

So, watching these codes I'd like to create a Volume Profile code (indicator) which plots an histogram for each single day (session) using ASCII scripts instead of trendlines.

It should be accurate to the tick, so I MUST calculate it on a tick chart.

Doing this, I've copied a DBantina logic (code):

on a 1 tick chart based on Trade Volume, calculate a range of each day and reset it each day.

**STEP ONE:**

//I've made a counter for each tick of the chart reset each day

if date > Date[1] then begin

MyOpen = open;

MyHigh = High;

MyLow = low;

MyClose = close;

counter = 1;

end;

If Date = date[1] then begin

If high > MyHigh then

MyHigh = High;

If Low < MyLow then

MyLow = Low;

if time >= Sess1endtime then

MyClose = close;

If time < Sess1endtime and lastbaronchart then

MyClose = close;

counter = counter + 1;

end;

RangeDay = MyHigh - MyLow;

**STEP TWO**

Then I have to identify the lines for each day for each Volume profile Histogram:

TickScale = minmove/priceScale;

NLines = RangeDay /TickScale;

**STEP Three**

Now I've to create an ARRAY (dinamic) to identify the volume for each line of the histogram.

I Think that this is correct.

MyVol = iff(bartype < 2, Upticks + Downticks, volume);

Array: HISTO[](0);

if date > date[1] then begin

Array_SetMaxIndex(Histo, NLines); // resize the array each day

HISTO[iPrice] = 0; // rest to zero each day

TotalVolume = 0;

END;

**STEP FOUR**

Now I've to populate the array with volume for each line level on each tick (1 tick chart).

for iPrice = 0 to NLines

begin

Histo[iPrice] = 0;

end;

for jBar = 0 to (counter-1)

begin

jLow = (L[jBar] - MyLow)/TickScale);

jHigh = (H[jBar] - MyLow)/TickScale);

if ((jHigh - jLow) > 0) then begin

deltaVol = MyVol[jBar]/(jHigh - jLow);

for iPrice = jLow to jHigh

begin

Histo[iPrice] = Histo[iPrice] + deltaVol;

TotalVolume = TotalVolume + deltaVol;

end;

end;

NOW if my thoughts are correct, the array Histo[iPrice] should be the Volume profile data and I've to Plot them using a way that permit me to plot ASCII scripts as in the TPO indicator.

AM I correct ???

Could someone give me an help to coding Volume Profile

At this point I don't know how to go on :crap:

THANKS

AndyTick

nutpstr (function - numeric).txt

]]>I’m want to code get the highest and lowest value in a period in the past. For example, I want to know the highest and lower value of S&P500 in period of Jan 01,2018 to Dec 31,2018 ( I can calculate the number of bars from beginning of period to now is 270 bars and the number of bars from ending period to now is 19 bars)

Please kindly help me the formulas in Amibroker to get the highest and lowest value (I am thinking of HHV and LLV but I failed)

Thanks you so much

]]>I am looking for a Tradestaion version of the Osma (Moving Average of Oscillator) found in Metatrader 4. Thanks.

]]>can you please help in code to define higher highs & lower lows in 3 or 4 charts with trend-line, i've been new to easy language and looking for help.

any available topics or help would be appreciated

Thanks,

]]>This is my first post here. And would like to gain some knowledge on a classic which was developed by E. Michael Poulos about 30 years back that were published in these TASC articles.

I use Amibroker as my Charting and TA tool. Like most of the other charting applications it too provides ready-made functions for the same:

1. RWIHi

2. RWILo

3. RWI

Adding the functions onto one section:

_SECTION_BEGIN( "Random Walk Index" ); minperiods = Param( "Min Periods", 9, 1, 200, 1 ); maxperiods = Param( "Max Periods", 40, 1, 200, 1 ); Plot( RwIHi( minperiods, maxperiods), "RwIHi", colorGreen, ParamStyle("Style") ); Plot( RwILO( minperiods, maxperiods), "RwILO", colorRed, ParamStyle("Style") ); Plot( RwI( minperiods, maxperiods), "RwI", colorWhite, ParamStyle("Style") ); _SECTION_END();

Objective is to replicate the inbuilt functions, by coding them raw from scratch for better understanding of the concept proposed by Poulos as Random Walk Index. I am unable to discern the use of two periods - minperiods, maxperiods - here. Well below is what I have so far managed to code "Random Walk Index of Highs" in Amibroker but the results do not match with the inbuilt ones. And need your kind help in this regard!

_SECTION_BEGIN( "Unveil RwIHi" ); mthd = ParamList( "Select Method", "Method 1|Method 2|Method 3", 1 ); pMin = Param( "Min Periods", 9, 1, 200, 1 ); pMax = Param( "Max Periods", 40, 1, 200, 1 ); switch( mthd ) { case "Method 1": // https://www.tradingview.com/script/eXHlEXzw-Random-Walk-Index-RWI-RWIhi-RWIlo/ RWH = 0; for( i = pMin; i <= pMax; i++ ) { RWH = IIf( i == pMin, ( H - L[ i ] ) / ( ATR( i ) * sqrt( i ) ), Max( ( H - L[ i ] ) / ( ATR( i ) * sqrt( i ) ), RWH ) ); } break; case "Method 2": // https://www.mail-archive.com/amibroker@yahoogroups.com/msg30080.html RWHmin = ( H - Ref( L, -pMin ) ) / ( Max( ATR( 1 ), ATR( pMin ) ) * sqrt( pMin ) ); RWHmax = ( H - Ref( L, -pMax ) ) / ( Max( ATR( 1 ), ATR( pMax ) ) * sqrt( pMax ) ); RWH = Max( RWHmin, RWHmax ); break; case "Method 3": // http://www.amibroker.com/members/library/detail.php?id=924&hilite=RWIHi VarMaxHi = 0; for( i = 5; i <= BarCount - 1; i++ ) { VarMaxHi[ i ] = Max( ( H[ i ] - L[ i - 1 ] ) / ( ( H[ i ] - L[ i ] ) * sqrt( i - 4 ) ), ( H[ i ] - L[ i - 2 ] ) / ( ( H[ i ] - L[ i ] ) * sqrt( i - 3 ) ) ); RWH[ i ] = Max( VarMaxHi[ i ], VarMaxHi[ i - 1 ] ); } break; } Title = "RWH: " + RWH; Plot( RWH, "RWH", ParamColor( "Color", colorCycle ), ParamStyle("Style") ); _SECTION_END();

Any suggestions?

**Thank you for reading. Appreciate your time!**

I'm trying to analyze price movement within its' contract lifetime window on some commodities futures. I'm interested in how much the price can go up or down from the defined start point (i.e. new contract starts) till end point (contract expires).

It's some kind of OHLC data, where O is price on open date (for example, CLQ3 starts on Jun 17th), C is price on close date (Jul 17th), H/L are high and low for this 30 days.

So, the first part will be to retrieve such OHLC data, ths second - to analyze maximum movement ranges by doing H-O and L-O math.

Any ideas? I've got thinkorswim live money account, but TOS has no export of daily data.

]]>Could someone post here his last TradeStation release 9.1.24 "easylanguagehelp.chm" file located in the program dir ?

https://www.tradestation.com/trading-technology/whats-new/tradestation-9-1

]]>

Could you please help me to convert the Turbo_JRSX.mq4 code below into

Tradestation Easylanguage.

Thank you in advance

Derek

---------------------------------------------------------------------------

http://www.mql5.com/en/code/viewcode/7900/44457/Turbo_JRSX.mq4

//+------------------------------------------------------------------+ //| | //| Copyright © 1999-2007, MetaQuotes Software Corp. | //| http://www.metaquotes.ru | //+------------------------------------------------------------------+ #property copyright "strategybuilderfx.com - modified by bluto to use typical price (HLC/3)" #property link "finger" //---- #property indicator_separate_window #property indicator_buffers 1 #property indicator_color1 Magenta #property indicator_level1 70 #property indicator_level2 30 #property indicator_level3 50 #property indicator_maximum 100 #property indicator_minimum 0 //---- input parameters extern int Len=14; //---- buffers double rsx[]; //+------------------------------------------------------------------+ //| | //+------------------------------------------------------------------+ int init() { SetIndexStyle(0,DRAW_LINE); SetIndexBuffer(0,rsx); IndicatorShortName("Turbo_JRSX"); return(0); } //+------------------------------------------------------------------+ //| | //+------------------------------------------------------------------+ int deinit() { return(0); } //+------------------------------------------------------------------+ //| | //+------------------------------------------------------------------+ int start() { double f88, f90; double f0, v4, v8, vC, v10, v14, v18, v20; double f8, f10, f18, f20, f28, f30, f38, f48, v1C; double f50, f58, f60, f68, f70, f78, f80, f40; //int counted_bars = IndicatorCounted(),limit,shift; //if (counted_bars<0) return(-1); //if (counted_bars>0) counted_bars--; double limit=Bars-(Len)-1; //if(counted_bars>Len) limit=Bars-counted_bars-1; for(int shift=limit;shift>=0;shift--) { if (f90==0.0) { f90=1.0; f0=0.0; if (Len-1>=5) f88=Len-1.0; else f88=5.0; // f8 = 100.0*(Close[shift]); // // Modified for median price // f8=100.0*((High[shift]+Low[shift]+Close[shift])/3); f18=3.0/(Len + 2.0); f20=1.0 - f18; } else { if (f88<=f90) f90=f88 + 1; else f90=f90 + 1; f10=f8; // f8 = 100*Close[shift]; f8=100.0*((High[shift]+Low[shift]+Close[shift])/3); v8=f8 - f10; f28=f20 * f28 + f18 * v8; f30=f18 * f28 + f20 * f30; vC=f28 * 1.5 - f30 * 0.5; f38=f20 * f38 + f18 * vC; f40=f18 * f38 + f20 * f40; v10=f38 * 1.5 - f40 * 0.5; f48=f20 * f48 + f18 * v10; f50=f18 * f48 + f20 * f50; v14=f48 * 1.5 - f50 * 0.5; f58=f20 * f58 + f18 * MathAbs(v8); f60=f18 * f58 + f20 * f60; v18=f58 * 1.5 - f60 * 0.5; f68=f20 * f68 + f18 * v18; f70=f18 * f68 + f20 * f70; v1C=f68 * 1.5 - f70 * 0.5; f78=f20 * f78 + f18 * v1C; f80=f18 * f78 + f20 * f80; v20=f78 * 1.5 - f80 * 0.5; //---- if ((f88>=f90) && (f8!=f10)) f0=1.0; if ((f88==f90) && (f0==0.0)) f90=0.0; } if ((f88 < f90) && (v20 > 0.0000000001)) { v4=(v14/v20 + 1.0) * 50.0; if (v4 > 100.0) v4=100.0; if (v4 < 0.0) v4=0.0; } else { v4=50.0; } rsx[shift]=v4; } //---- return(0); } //+------------------------------------------------------------------+]]>

]]>

The point is, I don't need fibonacci levels. I need levels at where prices worked as support or resistance in the past. Exactly as you see here in the link. Please let me know if you've seen this elsewhere already done. THANKS

]]>

This simple code works well and posts the proper Delta text value at the close of each bar. It also posts the text, only on the most recent 6 bars.

Variable:

Delta(Upticks-DownTicks ), {Holds Delta values}

DeltaTxt(0); {Holds Text Values}

If Delta <> 0 Then DeltaTxt = Text_New( D, time[1], (h+1.25), NumToStr( Delta, 0 ) );

{Above expression puts text 5 ticks above Hi of each bar}

Text_Delete(DeltaTxT[6]); {Gets rid of all DeltaTxt objects beyond the 6th barback}

Here's my delema. I wish to update the text intrabar so I have a running tally while building the last bar on the chart. If I enable "Tick by Tick update", I get new text objects piling up on each other so it quickly becomes unreadable.(See Image) Is there some code or coding technique that gets rid of the old text object as the new one is generated until the bar closes? I have played for several hours trying to get Text_Delete () to work but have received no joy. Any help,code or explanation greatly appreciated.

]]>Multiplying the number of pips with the exchange rate is needed which tells how much the account has appreciated or depreciated in value

]]>

Thanks!

]]>

def mybarcount = RoundUp(SecondsFromTime(0930) / 300, 0); def orHigh = GetValue(high, mybarcount); def orLow = GetValue(low, mybarcount); plot signal = if close > orHigh then 1 else if close < orLow then -1 else 0; AssignBackgroundColor(if signal == 1 then Color.Uptick else if signal == -1 then Color.Downtick else Color.DARK_GRAY); signal.AssignValueColor(if signal == 1 then Color.Uptick else if signal == -1 then Color.Downtick else Color.DARK_GRAY);]]>

I found 2 interesting and promissing indicators based on MT4 and would be happy to have them available for TS.

Anyone here "billangual" able to code MT4 and Easylanguage? Have MT4 code available and can post it.

Many thx in advance,

Goody

]]>]]>

In John F Ehlers Book " Cycle-Analytics-for-Traders "

The EasyLanguage code to compute the Convolution indicator is given in

Code Listing 13-1.

EasyLanguage Code to Compute and Display Convolution

/////////////////////////////////////////////////////////////////////////////

the line in the book and below is incomplete

i.e.

<<< If Filt[intPortion(.5*N)] < Filt Convolution[N] = (1 + (ExpValue Blank >>>

To get Indicator to run inserted the line below

<<< If (IntPortion(.5*N))>Filt then Convolution[N]=(1+ExpValue(N)); >>>

Could someone please correct this effort

///////////////////////////////////////////////////////////////////////////

See attached pdf " Ehlers Convolution Indicator" for the original code

Thank you in advance

Derek

The EasyLanguage code to compute the Convolution indicator is given in Code Listing 13-1. Code Listing 13-1. EasyLanguage Code to Compute and Display Convolution { Convolution Indicator (c) 2013 John F. Ehlers } Inputs: ShortestPeriod(40), LongestPeriod(80); Vars: alpha1(0), HP(0), a1(0), b1(0), c1(0), c2(0), c3(0), Filt(0), N(0), II(0), X(0), Y(0), Sx(0), Sy(0), Sxx(0), Syy(0), Sxy(0), Color1(0), Color2(0), Color3(0); Arrays: Corr[48](0), Slope[48](0), Convolution[48](0); //HighPass filter cyclic component alpha1 = (Cosine(1.414*360 / Longe HP = (1 - alpha1 / 2)* (1 - alpha1 / 2)* (Close - 2*Close[1] + Close[2]) + (1 - alpha1)*HP[1] - (1 - alpha1)* (1 - alpha1)*HP[2]; //Smooth with a Super Smoother Fil a1 = expvalue(-1.414*3.14159 / Sho b1 = 2*a1*Cosine(1.414*180 / Short c2 = b1; c3 = -a1*a1; c1 = 1 - c2 - c3; Filt = c1* (HP + HP[1]) / 2 + c2*Filt[1] + c3 For N = 1 to 48 Begin Sx = 0; Sy = 0; Sxx = 0; Syy = 0; Sxy = 0; For II = 1 to N Begin X = Filt[iI - 1]; Y = Filt[N - II]; Sx = Sx + X; Sy = Sy + Y; Sxx = Sxx + X*X; Sxy = Sxy + X*Y; Syy = Syy + Y*Y; End; If (N*Sxx - Sx*Sx)* (N*Syy - Sy*Sy) > 0 Then Corr[N] = (N*Syy - Sy*Sy)); Slope[N] = 1; {////////////////////////////////////////////////////////////////////////////////////////// In John F Ehlers Book " Cycle-Analytics-for-Traders" The EasyLanguage code to compute the Convolution indicator is given in Code Listing 13-1. the line in the book and below is incomplete i.e. <<< If Filt[intPortion(.5*N)] < Filt Convolution[N] = (1 + (ExpValue >>> To get Indicator to run substitued the line below <<< If (IntPortion(.5*N))>Filt then Convolution[N]=(1+ExpValue(N)); >>> Could someone please correct this effort /////////////////////////////////////////////////////////////////////////////////////////////} If (IntPortion(.5*N))>Filt then Convolution[N]=(1+ExpValue(N)); End; //Plot as a Heatmap For N = 3 to 48 Begin If Slope[N] > 0 Then Begin Color1 = 255*Convolution[N]; Color2 = 0; End; If Slope[N] < 0 Then Begin Color1 = 0; Color2 = 255*Convolution[N]; End; Color3 = 0; If N = 2 Then Plot2[4] (2, “S2”, RGB(Color1, Color2, Colo If N = 3 Then Plot3[4] (3, “S3”, RGB(Color1, Color2, Colo If N = 4 Then Plot4[4] (4, “S4”, RGB(Color1, Color2, Colo If N = 5 Then Plot5[4] (5, “S5”, RGB(Color1, Color2, Colo If N = 6 Then Plot6[4] (6, “S6”, RGB(Color1, Color2, Colo If N = 7 Then Plot7[4] (7, “S7”, RGB(Color1, Color2, Colo If N = 8 Then Plot8[4] (8, “S8”, RGB(Color1, Color2, Colo If N = 9 Then Plot9[4] (9, “S9”, RGB(Color1, Color2, Colo If N = 10 Then Plot10[4] (10, “S10”, RGB(Color1, Color2, Co If N = 11 Then Plot11[4] (11, “S11”, RGB(Color1, Color2, Co If N = 12 Then Plot12[4] (12, “S12”, RGB(Color1, Color2, Co If N = 13 Then Plot13[4] (13, “S13”, RGB(Color1, Color2, Co If N = 14 Then Plot14[4] (14, “S14”, RGB(Color1, Color2, Co If N = 15 Then Plot15[4] (15, “S15”, RGB(Color1, Color2, Co If N = 16 Then Plot16[4] (16, “S16”, RGB(Color1, Color2, Co If N = 17 Then Plot17[4] (17, “S17”, RGB(Color1, Color2, Co If N = 18 Then Plot18[4] (18, “S18”, RGB(Color1, Color2, Co If N = 19 Then Plot19[4] (19, “S19”, RGB(Color1, Color2, Co If N = 20 Then Plot20[4] (20, “S20”, RGB(Color1, Color2, Co If N = 21 Then Plot21[4] (21, “S21”, RGB(Color1, Color2, Co If N = 22 Then Plot22[4] (22, “S22”, RGB(Color1, Color2, Co If N = 23 Then Plot23[4] (23, “S23”, RGB(Color1, Color2, Co If N = 24 Then Plot24[4] (24, “S24”, RGB(Color1, Color2, Co If N = 25 Then Plot25[4] (25, “S25”, RGB(Color1, Color2, Co If N = 26 Then Plot26[4] (26, “S26”, RGB(Color1, Color2, Co If N = 27 Then Plot27[4] (27, “S27”, RGB(Color1, Color2, Co If N = 28 Then Plot28[4] (28, “S28”, RGB(Color1, Color2, Co If N = 29 Then Plot29[4] (29, “S29”, RGB(Color1, Color2, Co If N = 30 Then Plot30[4] (30, “S30”, RGB(Color1, Color2, Co If N = 31 Then Plot31[4] (31, “S31”, RGB(Color1, Color2, Co If N = 32 Then Plot32[4] (32, “S32”, RGB(Color1, Color2, Co If N = 33 Then Plot33[4] (33, “S33”, RGB(Color1, Color2, Co If N = 34 Then Plot34[4] (34, “S34”, RGB(Color1, Color2, Co If N = 35 Then Plot35[4] (35, “S35”, RGB(Color1, Color2, Co If N = 36 Then Plot36[4] (36, “S36”, RGB(Color1, Color2, Co If N = 37 Then Plot37[4] (37, “S37”, RGB(Color1, Color2, Co If N = 38 Then Plot38[4] (38, “S38”, RGB(Color1, Color2, Co If N = 39 Then Plot39[4] (39, “S39”, RGB(Color1, Color2, Co If N = 40 Then Plot40[4] (40, “S40”, RGB(Color1, Color2, Co If N = 41 Then Plot41[4] (4 , “S4 ”, RGB(Color1, Color2, Co If N = 42 Then Plot42[4] (4 , “S4 ”, RGB(Color1, Color2, Co If N = 43 Then Plot43[4] (4 , “S4 ”, RGB(Color1, Color2, Co If N = 44 Then Plot44[4] ( 4, “S 4”, RGB(Color1, Color2, Co If N = 45 Then Plot45[4] (4 , “S4 ”, RGB(Color1, Color2, Co If N = 46 Then Plot46[4] (4 , “S4 ”, RGB(Color1, Color2, Co If N = 47 Then Plot47[4] (4 , “S4 ”, RGB(Color1, Color2, Co If N = 48 Then Plot48[4] (4 , “S4 ”, RGB(Color1, Color2, Co End;]]>

May B It could help coders w/o TS platform 2 have the latest release of EasyLanguage help file

]]>