I am new to esignal. Can somebody show me how to make a simple indicator that measures the daily range (not the True Range), just the High - Low. Then I want to create a 10 day moving average of that range.
I had a slightly different way, using the formula wizard
//{{EFSWizard_Description
//
// This formula was generated by the Alert Wizard
//
//}}EFSWizard_Description 7532
//{{EFSWizard_Declarations
var vSMA10_of_High = new MAStudy(10, 0, "High", MAStudy.SIMPLE);
var vSMA10_of_Low = new MAStudy(10, 0, "Low", MAStudy.SIMPLE);
var vLastAlert = -1;
//}}EFSWizard_Declarations 20983
function preMain() {
/**
* This function is called only once, before any of the bars are loaded.
* Place any study or EFS configuration commands here.
*/
//{{EFSWizard_PreMain
setPriceStudy(false);
setStudyTitle("");
setCursorLabelName("MAdiff", 0);
setDefaultBarStyle(PS_DOT, 0);
setDefaultBarFgColor(Color.red, 0);
setDefaultBarThickness(1, 0);
setPlotType(PLOTTYPE_DOT, 0);
//}}EFSWizard_PreMain 27905
}
function main() {
/**
* The main() function is called once per bar on all previous bars, once per
* each incoming completed bar, and if you don't have 'setComputeOnClose(true)'
* in your preMain(), it is also called on every tick.
*/
function postMain() {
/**
* The postMain() function is called only once, when the EFS is no longer used for
* the current symbol (ie, symbol change, chart closing, or application shutdown).
*/
}
You might want to look at HiLoAverageRange1.efs and HiLOAverageRange2.efs. These were kindly coded up by Chris C. in response to my request a couple of months ago. You can find them in Specialty Scripts in the Miscellaneous folder. Certainly met my need.
Timber,
Sorry for the incomplete post below. Both the ones I mentioned are intraday.The efs you are more likely looking for is in the same Miscellaneous folder but named DailyRangeHist.efs.
It plots a histogram of daily HiLo Ranges with a user-definable MA line superimposed on it.
Comment