My code cannot display both the HH and LL at the same time.
If I leave both the
seriesHH=highest(252,high());
return seriesHH;
seriesLL=lowest(252,low());
return seriesLL;
statements in the code, it only displays the seriesHH.
If I comment out the seriesHH part (both lines), it only displays the seriesLL.
How do I get the code to display both?
It is frustrating being so miserably new to this.
Thanks, Perry
Here is the failing code:
var seriesHH=0;
var seriesLL=0;
function preMain() {
setStudyTitle("MMD252dH&L");
setCursorLabelName("MMD252dH&L",0);
setDefaultBarFgColor(Color.black,0);
setDefaultBarFgColor(Color.black,1);
setPriceStudy(true);
setPlotType( PLOTTYPE_LINE, 0 );
setPlotType( PLOTTYPE_LINE, 1 );
}
function main() {
seriesHH=highest(252,high());
return seriesHH;
seriesLL=lowest(252,low());
return seriesLL;
}
If I leave both the
seriesHH=highest(252,high());
return seriesHH;
seriesLL=lowest(252,low());
return seriesLL;
statements in the code, it only displays the seriesHH.
If I comment out the seriesHH part (both lines), it only displays the seriesLL.
How do I get the code to display both?
It is frustrating being so miserably new to this.
Thanks, Perry
Here is the failing code:
var seriesHH=0;
var seriesLL=0;
function preMain() {
setStudyTitle("MMD252dH&L");
setCursorLabelName("MMD252dH&L",0);
setDefaultBarFgColor(Color.black,0);
setDefaultBarFgColor(Color.black,1);
setPriceStudy(true);
setPlotType( PLOTTYPE_LINE, 0 );
setPlotType( PLOTTYPE_LINE, 1 );
}
function main() {
seriesHH=highest(252,high());
return seriesHH;
seriesLL=lowest(252,low());
return seriesLL;
}
Comment