


If you use the name value1 or value2 or value 99 as You can experiment with values like 0.1 and 0.9 to see the Slow average set factor to 1, to see the plot constructedĮntirely of the faster average you can set factor to 0. Slow average to 50% of the fast average and create a blended If factor is set to 0.5 it will add 50% of the The input called factor is adjustable to assign a weighting to

Inputs:length1(50),length2(20),factor(0.5) Ĭode first before creating this indicator and see if you canĪverages used with slow length of 50 and a fast length of 20, Period ) bars with all the 1 and -1 and 0 values.Įxperiment by trying it different values.īeginners example No.2 (Adjustable weighting percent blended moving average) Summation( move,length) This means the variable summove isĬreated from adding up the sum of the last 20 bars ( or length Variables are shown here as "vars" and these are values IĬreated to store the values outputted by the 3 lines of code The length to 50 or 20 or 100 to see how it affects the plot. Once you plot the indicator in its original form you can change The inputs written at the top represent values that canīe changed by the user when plotting the indicator on the chart. Then see your indicator plots a line which is either 1, -1 or 0 Plot1(move,"up-downcount") Then click compile. See how it works, you can change this line of code We have the summation of the last ( length 20 ) bars.

Would refer to the close 2 days or bars ago instead. On daily charts or minute charts and the close refers to the Or less that the closing price of yesterday. This code detects if the closing price today is greater than At the foot of the page are some coding rest materials which are relavant to tradingīeginners example No.1 ( Price up and down counter demonstration only)Ĭode above into your development environment in Tradestation or Taking regular brain breaks when coding can improve performance. Here in this guide I have made some simple to understand examples so you can learn what each part does - The grey - green panel are to make it easier on the eyes. Programming is a subject which can put fear into those who are trying to learn it.
