PDA

View Full Version : indicator that just paints the background


scjohn
06-08-2007, 07:42 PM
I am having a small problem with an indicator that can either plot the value on a panel, or through a parameter, plot the background based up the value of the indicator. I made a copy of the ROC indicator and saved it under myRoc. I have included the code for myROC.

This is the plot statement:
Add(new Plot(Color.Blue, "ROC"));

I assume that this defaults to PlotStyle.Line.

Add a indicator to a panel. Like HMA(Close,20); Need to ass an indicator so that the y-axis gets set. Now add myRoc(Close,True, 14) to the panel. Set the user parameter: BolPlotBckGrnd to True. As far as I can tell it does not make any difference if Auto scale is true or false.

Using this setup, try changing the Plot Style from Line to Dot, Hash, and Square. All of these styles have no effect on the y-axis. Now try, Style = Bar. Notice how the y-axis has now changed even though nothing is being plotted. And Auto scale = True or False makes no difference.

Is this by design or is this a bug.
Thanks,

NinjaTrader_Dierk
06-09-2007, 12:09 AM
This is expected behavior: back color changes will not be effective unless you set value for the plot series.

However, we will put that to our list to improve.