[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Plot Calc Help



PureBytes Links

Trading Reference Links

				Can someone provide me some information
about the "DLL" that the Omega Support person is referring to?

				When I run this on different charts, I have
to manually try and figure out what the input (percentfactor) is.  How can I
code this so that it will do this figuring automatically, for each symbol
its applied to.  It is based on the percentage of bars that fall outside the
channel.
				Specifically, I would like the code to:
Calculate the PercentFactor by looking at the last 500 bars and allowing
only 3% of the bars to fall outside (above/below) the channel.

				Couldn't we code a function that will use a
loop to keep adjusting the channel until it is right?

				Thanks
				Jeff


Thank you for your reply.

When an analysis technique is applied to a chart, EasyLanguage works left to
right on a bar by bar basis. Once a plot is drawn it can not be moved, which
would require that if you wish to use a consistent PercentFactor value on
all bars the PercentFactor should be determined after all of the chart
values have been read. Then the values should be calculated and plotted.

In order to plot on all of the bars of a chart, this would require passing
through the chart more than once. This is not possible via EasyLanguage and
may be done using a DLL, by reading all of the chart values to determine the
proper PercentFactor. Once that is done, the EasyLanguage used for the basic
technique can be executed "bar by bar". 

Thank you for choosing Omega Research, Inc.

Julio Zayas
EasyLanguage Specialist
Omega Research, Inc.




				******************200 Day Channel
Indicator*********************************

				Inputs: Price(Close), Length(200),
Displace(100); 
				Variables: X(0), PercentFactor(?);

				Value1 = Average(Price, Length);
				Value2 = Average(Price, Length) * (1 +
PercentFactor);
				Value3 = Average(Price, Length) * (1 -
PercentFactor);

				IF CurrentBar > AbsValue(Displace) Then
BEGIN

				Plot1[Displace](Value1, "CMA");
				Plot2[Displace](Value2, "Uppr Chan");
				Plot3[Displace](Value3, "Lowr Chan");

END;