AUS Market Sector Based Index Filter if have both US and AUS data
_SECTION_BEGIN(“AUS Sector Index Filter”);
SectorIndextog = ParamToggle(“Sector Index Filter”,”On|Off”,1);
sectorIndexCode = SectorIndexAUS = IIf(InGics(“10”),Foreign(“$XEJ.au”,”C”),
IIf(InGics(“15”),Foreign(“$XMJ.au”,”C”),
IIf(InGics(“20”),Foreign(“$XNJ.au”,”C”),
IIf(InGics(“25”),Foreign(“$XDJ.au”,”C”),
IIf(InGics(“30”),Foreign(“$XSJ.au”,”C”),
IIf(InGics(“35”),Foreign(“$XHJ.au”,”C”),
IIf(InGics(“40”),Foreign(“$XFJ.au”,”C”),
IIf(InGics(“45”),Foreign(“$XIJ.au”,”C”),
IIf(InGics(“50”),Foreign(“$XTJ.au”,”C”),
IIf(InGics(“55”),Foreign(“$XUJ.au”,”C”),Foreign(“$XPJ.au”,”C”)))))))))));
SectorIndmaper = param(“Sector Index Filter MA Periods”,200,40,400,20);
sectorIndexfilterup = sectorindexcode > MA(sectorindexcode,sectorindmaper);
sectorIndexupfilt = IIf(sectorindextog,1,sectorindexfilterup);
_SECTION_END();