Stock Portfolio Organizer

The ultimate porfolio management solution.

Shares, Margin, CFD's, Futures and Forex
EOD and Realtime
Dividends and Trust Distributions
And Much More ....
For Portfolio Manager Click Here

WiseTrader Toolbox

#1 Selling Amibroker Plugin featuring:

Advanced Adaptive Indicators
Advanced Pattern Exploration
Neural Networks
And Much More ....
Find Out More Here

Sector Analysis System for Amibroker (AFL)

Rating:
2 / 5 (Votes 5)
Tags:
amibroker

Sector Analysis System ……..this indicator allows you to compare sectors of the Bangladesh stock exchange. Each sector is made up of a pool of stocks. See the code for more details.

Screenshots

Indicator / Formula

Copy & Paste Friendly
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
//================================================== ===================
//background stock name (works only on Amibroker version 5.30 onwards.
//================================================== ===================
_SECTION_BEGIN("Name");
GfxSetOverlayMode(1);
GfxSelectFont("Tahoma", Status("pxheight")/12 );
GfxSetTextAlign( 6 );// center alignment
//GfxSetTextColor( ColorRGB( 220, 220, 220 ) );
GfxSetTextColor( ColorHSB( 111, 111, 111 ) );
GfxSetBkMode(0); // transparent
GfxTextOut( Name(), Status("pxwidth")/2, Status("pxheight")/12 );
GfxSelectFont("Tahoma", Status("pxheight")/18 );
GfxTextOut( "Sector Analysis", Status("pxwidth")/2, Status("pxheight")/5 );
GfxSelectFont("Tahoma", Status("pxheight")/36 );
_SECTION_END();
//================================================== ====================================//Sector Analysing.....copy right @ Rafi......E-Mail rafi80@yahoo.com
N=Param("Smoother",5, 1, 100, 1 );
 
_SECTION_BEGIN("BANK");
BANK = ParamToggle("BANK","Off|On",0);
S1 = Foreign( "ABBANK", "Close" ) ;
S2 = Foreign( "ALARABANK", "Close" ) ;
S3 = Foreign( "BANKASIA", "Close" ) ;
S4 = Foreign( "BRACBANK", "Close" ) ;
S5 = Foreign( "CITYBANK", "Close" ) ;
S6 = Foreign( "DHAKABANK", "Close" ) ;
S7 = Foreign( "DUTCHBANGL", "Close" ) ;
S8 = Foreign( "EBL", "Close" ) ;
S9 = Foreign( "EXIMBANK", "Close" ) ;
S10= Foreign( "FIRSTSBANK", "Close" ) ;
S11= Foreign( "ICBIBANK", "Close" ) ;
S12= Foreign( "IFIC", "Close" ) ;
S13= Foreign( "ISLAMIBANK", "Close" ) ;
S14= Foreign( "JAMUNABANK", "Close" ) ;
S15= Foreign( "MERCANBANK", "Close" ) ;
S16= Foreign( "MTBL", "Close" ) ;
S17= Foreign( "NBL", "Close" ) ;
S18= Foreign( "NCCBANK", "Close" ) ;
S19= Foreign( "ONEBANKLTD", "Close" ) ;
S20= Foreign( "PREMIERBAN", "Close" ) ;
S21= Foreign( "PRIMEBANK", "Close" ) ;
S22= Foreign( "PUBALIBANK", "Close" ) ;
S23= Foreign( "RUPALIBANK", "Close" ) ;
S24= Foreign( "SHAHJABANK", "Close" ) ;
S25= Foreign( "SIBL", "Close" ) ;
S26= Foreign( "SOUTHEASTB", "Close" ) ;
S27= Foreign( "STANDBANKL", "Close" ) ;
S28= Foreign( "TRUSTBANK", "Close" ) ;
S29= Foreign( "UCBL", "Close" ) ;
S30= Foreign( "UTTARABANK", "Close" ) ;
AvgBankClose = (S1+S2+S3+S4+S5+S6+S7+S8+S9+S10+S11+S12+S13+S14+S15+S16+S17+S18+S19+S20+ S21+S22+S23+S24+S25+S26+S27+S28+S29+S30)/30;Banksmoother=MA(AvgBankClose,N);
if(BANK==1)
Plot(Banksmoother,"", ParamColor( "Bank Color", colorRed ), ParamStyle("Bank Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Insurance");
Insurance = ParamToggle("Insurance","Off|On",0);
in1 = Foreign( "AGRANINS", "Close" ) ;
in2 = Foreign( "ASIAINS", "Close" ) ;
in3 = Foreign( "ASIAPACINS", "Close" ) ;
in4 = Foreign( "BGIC", "Close" ) ;
in5 = Foreign( "CENTRALINS", "Close" ) ;
in6 = Foreign( "CITYGENINS", "Close" ) ;
in7 = Foreign( "CONTININS", "Close" ) ;
in8 = Foreign( "DELTALIFE", "Close" ) ;
in9 = Foreign( "DHAKAINS", "Close" ) ;
in10= Foreign( "EASTERNINS", "Close" ) ;
in11= Foreign( "EASTLAND", "Close" ) ;
in12= Foreign( "FAREASTLIF", "Close" ) ;
in13= Foreign( "FEDERALINS", "Close" ) ;
in14= Foreign( "GLOBALINS", "Close" ) ;
in15= Foreign( "GREENDELT", "Close" ) ;
in16= Foreign( "ISLAMIINS", "Close" ) ;
in17= Foreign( "JANATAINS", "Close" ) ;
in18= Foreign( "KARNAPHULI", "Close" ) ;
in19= Foreign( "MEGHNALIFE", "Close" ) ;
in20= Foreign( "MERCINS", "Close" ) ;
in21= Foreign( "NATLIFEINS", "Close" ) ;
in22= Foreign( "NITOLINS", "Close" ) ;
in23= Foreign( "NORTHRNINS", "Close" ) ;
in24= Foreign( "PARAMOUNT", "Close" ) ;
in25= Foreign( "PEOPLESINS", "Close" ) ;
in26= Foreign( "PHENIXINS", "Close" ) ;
in27= Foreign( "PIONEERINS", "Close" ) ;
in28= Foreign( "POPULARLIF", "Close" ) ;
in29= Foreign( "PRAGATIINS", "Close" ) ;
in30= Foreign( "PRAGATILIF", "Close" ) ;
in31= Foreign( "PRIMEINSUR", "Close" ) ;
in32= Foreign( "PRIMELIFE", "Close" ) ;
in33= Foreign( "PROGRESLIF", "Close" ) ;
in34= Foreign( "PROVATIINS", "Close" ) ;
in35= Foreign( "PURABIGEN", "Close" ) ;
in36= Foreign( "RELIANCINS", "Close" ) ;
in37= Foreign( "REPUBLIC", "Close" ) ;
in38= Foreign( "RUPALIINS", "Close" ) ;
in39= Foreign( "RUPALILIFE", "Close" ) ;
in40= Foreign( "SANDHANINS", "Close" ) ;
in41= Foreign( "SONARBAINS", "Close" ) ;
in42= Foreign( "STANDARINS", "Close" ) ;
in43= Foreign( "TAKAFULINS", "Close" ) ;
in44= Foreign( "UNITEDINS", "Close" ) ;
AvgGeneralInsuranceClose = (IN1+IN2+IN3+IN4+IN5+IN6+IN7+IN8+IN9+IN10+IN11+IN12+IN13+IN14+IN15+IN16+IN17+IN18+IN19+IN20+IN21+IN22+IN23+IN24+IN25+IN26+IN27+IN28+IN29+IN30+IN31+IN32+IN33+IN34+IN35+IN36+IN37+IN38+IN39+IN40+IN41+IN42+IN43+IN44)/44;
GeneralInsurancesmoother=MA(AvgGeneralInsuranceClose,N);
if(Insurance==1)
Plot(GeneralInsurancesmoother,"", ParamColor( "Gen.Ins Color", colorYellow ), ParamStyle("Gen.Ins Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Financial Institutions");
Financial = ParamToggle("Financial","Off|On",0);
f1 = Foreign( "BAYLEASING", "CLOSE" ) ;
f2 = Foreign( "BDFINANCE", "CLOSE" ) ;
f3 = Foreign( "BIFC", "CLOSE" ) ;
f4 = Foreign( "DBH", "CLOSE" ) ;
f5 = Foreign( "FLEASEINT", "CLOSE" ) ;
f6 = Foreign( "ICB", "CLOSE" ) ;
f7 = Foreign( "IDLC", "CLOSE" ) ;
f8 = Foreign( "ILFSL", "CLOSE" ) ;
f9 = Foreign( "IPDC", "CLOSE" ) ;
f10= Foreign( "ISLAMICFIN", "CLOSE" ) ;
f11= Foreign( "LANKABAFIN", "CLOSE" ) ;
f12= Foreign( "MIDASFIN", "CLOSE" ) ;
f13= Foreign( "NHFIL", "CLOSE" ) ;
f14= Foreign( "PHOENIXFIN", "CLOSE" ) ;
f15= Foreign( "PLFSL", "CLOSE" ) ;
f16= Foreign( "PREMIERLEA", "CLOSE" ) ;
f17= Foreign( "PRIMEFIN", "CLOSE" ) ;
f18= Foreign( "ULC", "CLOSE" ) ;
f19= Foreign( "UNIONCAP", "CLOSE" ) ;
f20= Foreign( "UTTARAFIN", "CLOSE" ) ;
AvgFinanceClose=(f1+f2+f3+f4+f5+f6+f7+f8+f9+f10+f11+f12+f13+f14+f15+f16+f17+f18+f19+f20)/20;
Financesmoother=MA(AvgFinanceClose,N);
if(Financial==1)
Plot(Financesmoother,"", ParamColor( "Finance Color", colorBrightGreen ), ParamStyle("Finance Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Engineering");
Engineering = ParamToggle("Engineering","Off|On",0);
en1 = Foreign( "AFTABAUTO", "Close" ) ;
en2 = Foreign( "ANWARGALV", "Close" ) ;
en3 = Foreign( "ATLASBANG", "Close" ) ;
en4 = Foreign( "AZIZPIPES", "Close" ) ;
en5 = Foreign( "BDAUTOCA", "Close" ) ;
en6 = Foreign( "BDLAMPS", "Close" ) ;
en7 = Foreign( "BDTHAI", "Close" ) ;
en8 = Foreign( "BSRMSTEEL", "Close" ) ;
en9 = Foreign( "DESHBANDHU", "Close" ) ;
en10 = Foreign( "ECABLES", "Close" ) ;
en11 = Foreign( "GOLDENSON", "Close" ) ;
en12 = Foreign( "KAY&QUE", "Close" ) ;
en13 = Foreign( "MONNOSTAF", "Close" ) ;
en14 = Foreign( "NAVANACNG", "Close" ) ;
en15 = Foreign( "NPOLYMAR", "Close" ) ;
en16 = Foreign( "NTLTUBES", "Close" ) ;
en17 = Foreign( "OLYMPIC", "Close" ) ;
en18 = Foreign( "QSMDRYCELL", "Close" ) ;
en19 = Foreign( "RANFOUNDRY", "Close" ) ;
en20 = Foreign( "RENWICKJA", "Close" ) ;
en21 = Foreign( "SALAMCRST", "Close" ) ;
en22 = Foreign( "SINGERBD", "Close" ) ;
 
AvgEngineeringClose= (en1+en2+en3+en4+en5+en6+en7+en8+en9+en10+en11+en12+en13+en14+en15+en16+en17+en18+en19+en20+en21+en22)/22;
Engineeringsmoother=MA(AvgEngineeringClose,N);
if(Engineering==1)
Plot(Engineeringsmoother,"", ParamColor( "Engineering Color", colorTurquoise ), ParamStyle("Engineering Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Textile");
Textile = ParamToggle("Textile","Off|On",0);
L1 = Foreign( "AL-HAJTEX", "Close" ) ;
L2 = Foreign( "ALLTEX", "Close" ) ;
L3 = Foreign( "ANLIMAYARN", "Close" ) ;
L4 = Foreign( "APEXSPINN", "Close" ) ;
L5 = Foreign( "CMCKAMAL", "Close" ) ;
L6 = Foreign( "DACCADYE", "Close" ) ;
L7 = Foreign( "DELTASPINN", "Close" ) ;
L8 = Foreign( "DSHGARME", "Close" ) ;
L9 = Foreign( "DULAMIACOT", "Close" ) ;
L10 = Foreign( "HRTEX", "Close" ) ;
L11 = Foreign( "MAKSONSPIN", "Close" ) ;
L12 = Foreign( "MALEKSPIN", "Close" ) ;
L13 = Foreign( "METROSPIN", "Close" ) ;
L14 = Foreign( "MITHUNKNIT", "Close" ) ;
L15 = Foreign( "MODERNDYE", "Close" ) ;
L16 = Foreign( "PRIMETEX", "Close" ) ;
L17 = Foreign( "RAHIMTEXT", "Close" ) ;
L18 = Foreign( "RNSPIN", "Close" ) ;
L19 = Foreign( "SAFKOSPINN", "Close" ) ;
L20 = Foreign( "SAIHAMTEX", "Close" ) ;
L21 = Foreign( "SONARGAON", "Close" ) ;
L22 = Foreign( "SQUARETEXT", "Close" ) ;
L23 = Foreign( "STYLECRAFT", "Close" ) ;
L24 = Foreign( "TALLUSPIN", "Close" ) ;
AvgTextileClose= (L1+L2+L3+L4+L5+L6+L7+L8+L9+L10+L11+L12+L13+L14+L15+L16+L17+L18+L19+L20+L21+L22+L23+L24)/24;
Textilesmoother=MA(AvgTextileClose,N) ;
if(Textile==1)
Plot(Textilesmoother,"", ParamColor( "Textile Color", colorWhite ), ParamStyle("Textile Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Fuel & Power");
FuelPower = ParamToggle("FuelPower","Off|On",0);
fp1 = Foreign( "BDWELDING", "Close" ) ;
fp2 = Foreign( "DESCO", "Close" ) ;
fp3 = Foreign( "EASTRNLUB", "Close" ) ;
fp4 = Foreign( "JAMUNAOIL", "Close" ) ;
fp5 = Foreign( "KPCL", "Close" ) ;
fp6 = Foreign( "MPETROLEUM", "Close" ) ;
fp7 = Foreign( "PADMAOIL", "Close" ) ;
fp8 = Foreign( "POWERGRID", "Close" ) ;
fp9 = Foreign( "SUMITPOWER", "Close" ) ;
fp10= Foreign( "TITASGAS", "Close" ) ;
AvgFuelPowerClose= (fp1+fp2+fp3+fp4+fp5+fp6+fp7+fp8+fp9+fp10)/10;
FuelPowersmoother=MA(AvgFuelPowerClose,N);
if(FuelPower==1)
Plot(FuelPowersmoother,"", ParamColor( "Power Color", colorLightBlue ), ParamStyle("FuelPower Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Cement");
Cement = ParamToggle("Cement","Off|On",0);
tt1 = Foreign( "ARAMITCEM", "Close" ) ;
tt2 = Foreign( "CONFIDCEM", "Close" ) ;
tt3 = Foreign( "HEIDELBCEM", "Close" ) ;
tt4 = Foreign( "LAFSURCEML", "Close" ) ;
tt5 = Foreign( "MEGHNACEM", "Close" ) ;
tt6 = Foreign( "MICEMENT", "Close" ) ;
 
AvgCementClose= (tt1+tt2+tt3+tt4+tt5+tt6)/6;
Cementsmoother=MA(AvgCementClose,N);
if(Cement==1)
Plot(Cementsmoother,"", ParamColor( "Cement Color", colorPaleGreen ), ParamStyle("Cement Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Ceramics");
Ceramics = ParamToggle("Ceramics","Off|On",0);
cm1 = Foreign( "FUWANGCER", "Close" ) ;
cm2 = Foreign( "MONNOCERA", "Close" ) ;
cm3 = Foreign( "RAKCERAMIC", "Close" ) ;
cm4 = Foreign( "SPCERAMICS", "Close" ) ;
cm5 = Foreign( "STANCERAM", "Close" ) ;
 
AvgCeramicsClose=(cm1+cm2+cm3+cm4+cm5)/5;
Ceramicssmoother=MA(AvgCeramicsClose,N);
if(Ceramics==1)
Plot(Ceramicssmoother,"", ParamColor( "Ceramics Color", colorPink ), ParamStyle("Ceramics Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Pharma & Chemicals");
PharmaChemicals = ParamToggle("PharmaChemicals","Off|On",0);
pc1 = Foreign( "ACI", "Close" ) ;
pc2 = Foreign( "ACIFORMULA", "Close" ) ;
pc3 = Foreign( "ACTIVEFINE", "Close" ) ;
pc4 = Foreign( "AMBEEPHA", "Close" ) ;
pc5 = Foreign( "BEACONPHAR", "Close" ) ;
pc6 = Foreign( "BXPHARMA", "Close" ) ;
pc7 = Foreign( "BXSYNTH", "Close" ) ;
pc8 = Foreign( "GLAXOSMITH", "Close" ) ;
pc9 = Foreign( "IBNSINA", "Close" ) ;
pc10 = Foreign( "IMAMBUTTON", "Close" ) ;
pc11 = Foreign( "KEYACOSMET", "Close" ) ;
pc12 = Foreign( "KOHINOOR", "Close" ) ;
pc13 = Foreign( "LIBRAINFU", "Close" ) ;
pc14 = Foreign( "MARICO", "Close" ) ;
pc15 = Foreign( "ORIONINFU", "Close" ) ;
pc16 = Foreign( "PHARMAID", "Close" ) ;
pc17 = Foreign( "RECKITTBEN", "Close" ) ;
pc18 = Foreign( "RENATA", "Close" ) ;
pc19 = Foreign( "SALVOCHEM", "Close" ) ;
pc20 = Foreign( "SQURPHARMA", "Close" ) ;
 
AvgPharmaChemicalsClose = (pc1+pc2+pc3+pc4+pc5+pc6+pc7+pc8+pc9+pc10+pc11+pc12+pc13+pc14+pc15+pc16+pc17+pc18+pc19+pc20)/20;PharmaChemicalssmoother=MA(AvgPharmaChemicalsClose,N);
if(PharmaChemicals==1)
Plot(PharmaChemicalssmoother,"", ParamColor( "PharmaChemicals Color", colorLime ), ParamStyle("PharmaChemicals Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Food & Alied");
FoodAlied = ParamToggle("FoodAlied","Off|On",0);
fd1 = Foreign( "AMCL(PRAN)", "Close" ) ;
fd2 = Foreign( "APEXFOODS", "Close" ) ;
fd3 = Foreign( "BANGAS", "Close" ) ;
fd4 = Foreign( "BATBC", "Close" ) ;
fd5 = Foreign( "BEACHHATCH", "Close" ) ;
fd6 = Foreign( "FINEFOODS", "Close" ) ;
fd7 = Foreign( "FUWANGFOOD", "Close" ) ;
fd8 = Foreign( "GEMINISEA", "Close" ) ;
fd9 = Foreign( "MEGCONMILK", "Close" ) ;
fd10 = Foreign( "MEGHNAPET", "Close" ) ;
fd11 = Foreign( "NTC", "Close" ) ;
fd12 = Foreign( "RAHIMAFOOD", "Close" ) ;
fd13 = Foreign( "SHYAMPSUG", "Close" ) ;
fd14 = Foreign( "ZEALBANGLA", "Close" ) ;
 
AvgFoodAliedClose= (fd1+fd2+fd3+fd4+fd5+fd6+fd7+fd8+fd9+fd10+fd11+fd12+fd13+fd14)/14;
FoodAliedsmoother=MA(AvgFoodAliedClose,N);
if(FoodAlied==1)
Plot(FoodAliedsmoother,"", ParamColor( "FoodAlied Color", colorOrange ), ParamStyle("FoodAlied Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Tannery");
Tannery = ParamToggle("Tannery","Off|On",0);
tn1 = Foreign( "APEXADELFT", "Close" ) ;
tn2 = Foreign( "APEXTANRY", "Close" ) ;
tn3 = Foreign( "BATASHOE", "Close" ) ;
tn4 = Foreign( "LEGACYFOOT", "Close" ) ;
tn5 = Foreign( "SAMATALETH", "Close" ) ;
 
AvgTanneryClose= (tn1+tn2+tn3+tn4+tn5)/5;
Tannerysmoother=MA(AvgTanneryClose,N);
if(Tannery==1)
Plot(Tannerysmoother,"", ParamColor( "Tannery Color", colorTan ), ParamStyle("Tannery Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Mutual Funds");
MutualFunds = ParamToggle("MutualFunds","Off|On",0);
f1 = Foreign( "1JANATAMF", "Close" ) ;
f2 = Foreign( "1STBSRS", "Close" ) ;
f3 = Foreign( "1STICB", "Close" ) ;
f4 = Foreign( "1STPRIMFMF", "Close" ) ;
f5 = Foreign( "2NDICB", "Close" ) ;
f6 = Foreign( "3RDICB", "Close" ) ;
f7 = Foreign( "4THICB", "Close" ) ;
f8 = Foreign( "5THICB", "Close" ) ;
f9 = Foreign( "6THICB", "Close" ) ;
f10 = Foreign( "7THICB", "Close" ) ;
f11 = Foreign( "8THICB", "Close" ) ;
f12 = Foreign( "AIBL1STIMF", "Close" ) ;
f13 = Foreign( "AIMS1STMF", "Close" ) ;
f14 = Foreign( "DBH1STMF", "Close" ) ;
f15 = Foreign( "EBL1STMF", "Close" ) ;
f16 = Foreign( "EBLNRBMF", "Close" ) ;
f17 = Foreign( "GRAMEEN1", "Close" ) ;
f18 = Foreign( "GRAMEENS2", "Close" ) ;
f19 = Foreign( "GREENDELMF", "Close" ) ;
f20 = Foreign( "ICB1STNRB", "Close" ) ;
f21 = Foreign( "ICB2NDNRB", "Close" ) ;
f22 = Foreign( "ICB3RDNRB", "Close" ) ;
f23 = Foreign( "ICBAMCL1ST", "Close" ) ;
f24 = Foreign( "ICBAMCL2ND", "Close" ) ;
f25 = Foreign( "ICBEPMF1S1", "Close" ) ;
f26 = Foreign( "ICBISLAMIC", "Close" ) ;
f27 = Foreign( "IFIC1STMF", "Close" ) ;
f28 = Foreign( "IFILISLMF1", "Close" ) ;
f29 = Foreign( "MBL1STMF", "Close" ) ;
f30 = Foreign( "PF1STMF", "Close" ) ;
f31 = Foreign( "PHPMF1", "Close" ) ;
f32 = Foreign( "POPULAR1MF", "Close" ) ;
f33 = Foreign( "PRIME1ICBA", "Close" ) ;
f34 = Foreign( "RELIANCE1", "Close" ) ;
f35 = Foreign( "SEBL1STMF", "Close" ) ;
f36 = Foreign( "TRUSTB1MF", "Close" ) ;
 
AvgMFClose=(f1+f2+f3+f4+f5+f6+f7+f8+f9+f10+f11+f12 +f13+f14+f15+f16+f17+f18+f19+f20+f21+f22+f23+f24+f25+f26+f27+f28+f29+f30+f31+f32+f34+f35+f36)/36;
MFsmoother=MA(AvgMFClose,N);
if(MutualFunds==1)
Plot(MFsmoother,"", ParamColor( "MF Color", colorBlue ), ParamStyle("MF Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Jute");
Jute = ParamToggle("Jute","Off|On",0);
jt1 = Foreign( "JUTESPINN", "Close" ) ;
jt2 = Foreign( "NORTHERN", "Close" ) ;
jt3 = Foreign( "SONALIANSH", "Close" ) ;
 
AvgJuteClose=(jt1+jt2+jt3)/3;
Jutesmoother=MA(AvgJuteClose,N);
if(Jute==1)
Plot(Jutesmoother,"", ParamColor( "Jute Color", colorGold ), ParamStyle("Jute Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Miscellaneous");
Miscellaneous = ParamToggle("Miscellaneous","Off|On",0);
e1 = Foreign( "ARAMIT", "Close" ) ;
e2 = Foreign( "BERGERPBL", "Close" ) ;
e3 = Foreign( "BEXIMCO", "Close" ) ;
e4 = Foreign( "BSC", "Close" ) ;
e5 = Foreign( "GQBALLPEN", "Close" ) ;
e6 = Foreign( "MIRACLEIND", "Close" ) ;
e7 = Foreign( "SAVAREFR", "Close" ) ;
e8 = Foreign( "SINOBANGLA", "Close" ) ;
e9 = Foreign( "USMANIAGL", "Close" ) ;
 
AvgMiscellaneousClose= (e1+e2+e3+e4+e5+e6+e7+e8+e9)/6;
Miscellaneoussmoother=MA(AvgMiscellaneousClose,N);
if(Miscellaneous==1)
Plot(Miscellaneoussmoother,"", ParamColor( "Miscellaneous Color", colorAqua ), ParamStyle("Miscellaneous Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Services & Real Estate");
ServicesRealEstate = ParamToggle("ServicesRealEstate","Off|On",0);
sr1 = Foreign( "BDSERVICE", "Close" ) ;
sr2 = Foreign( "EHL", "Close" ) ;
sr3 = Foreign( "OCL", "Close" ) ;
sr4 = Foreign( "SAMORITA", "Close" ) ;
sr5 = Foreign( "SAPORTL", "Close" ) ;
 
AvgServicesRealEstateClose=(sr1+sr2+sr3+sr4+sr5)/5;
ServicesRealEstatesmoother=MA(AvgServicesRealEstateClose,N);
if(ServicesRealEstate==1)
Plot(ServicesRealEstatesmoother,"", ParamColor( "ServicesRealEstate Color", colorBrown ), ParamStyle("ServicesRealEstate Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Telecommunication");
Telecommunication = ParamToggle("Telecommunication","Off|On",0);
tl1 = Foreign( "GP", "Close" ) ;
 
AvgTelecommunicationClose=(tl1)/1;
Telecommunicationsmoother=MA(AvgTelecommunicationClose,N);
if(Telecommunication==1)
Plot(Telecommunicationsmoother,"", ParamColor( "Telecommunication Color", colorViolet ), ParamStyle("Telecommunication Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("IT Sector");
IT = ParamToggle("IT","Off|On",0);
IT1 = Foreign( "AGNISYSL", "Close" ) ;
IT2 = Foreign( "BDCOM", "Close" ) ;
IT3 = Foreign( "DAFODILCOM", "Close" ) ;
IT4 = Foreign( "INTECH", "Close" ) ;
IT5 = Foreign( "ISNLTD", "Close" ) ;
AvgITClose= (IT1+IT2+IT3+IT4+IT5)/5;
ITsmoother=MA(AvgITClose,N);
if(IT==1)
Plot(ITsmoother,"", ParamColor( "IT Color", colorPaleBlue ), ParamStyle("IT Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
 
_SECTION_BEGIN("Travel & Leisure");
TravelLeisure = ParamToggle("TravelLeisure","Off|On",0);
tv1 = Foreign( "UNITEDAIR", "Close" ) ;
 
AvgTravelLeisureClose=(tv1)/1;
TravelLeisuresmoother=MA(AvgTravelLeisureClose,N);
if(TravelLeisure==1)
Plot(TravelLeisuresmoother,"", ParamColor( "TravelLeisure Color", colorLightGrey ), ParamStyle("TravelLeisure Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("Paper & Printing");
PaperPrinting = ParamToggle("PaperPrinting","Off|On",0);
pp1 = Foreign( "HAKKANIPUL", "Close" ) ;
 
AvgPaperPrintingClose=(pp1)/1;
PaperPrintingsmoother=MA(AvgPaperPrintingClose,N);
if(PaperPrinting==1)
Plot(PaperPrintingsmoother,"", ParamColor( "PaperPrinting Color", colorLavender ), ParamStyle("PaperPrinting Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
 
_SECTION_BEGIN("Corporate Bond");
CorporateBond = ParamToggle("CorporateBond","Off|On",0);
cb1 = Foreign( "ACIZCBOND", "Close" ) ;
cb2 = Foreign( "BRACSCBOND", "Close" ) ;
cb3 = Foreign( "IBBLPBOND", "Close" ) ;
 
AvgCorporateBondClose=(cb1+Cb2+Cb3)/3;
CorporateBondsmoother=MA(AvgCorporateBondClose,N);
if(CorporateBond==1)
Plot(CorporateBondsmoother,"", ParamColor( "CorporateBond Color", colorSkyblue ), ParamStyle("CorporateBond Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
_SECTION_BEGIN("New/Uncategorized");
NewUncategorized = ParamToggle("NewUncategorized","Off|On",0);
nu1 = Foreign( "BEDL", "Close" ) ;
nu2 = Foreign( "CVOPRL", "Close" ) ;
nu3 = Foreign( "EBLNRBMF", "Close" ) ;
nu4 = Foreign( "FASFIN", "Close" ) ;
nu5 = Foreign( "LINDBD", "Close" ) ;
nu6 = Foreign( "LRGLOBMF1", "Close" ) ;
nu7 = Foreign( "MJLBD", "Close" ) ;
nu8 = Foreign( "RDFOOD", "Close" ) ;
nu9 = Foreign( "RELIANCE1", "Close" ) ;
nu10 = Foreign( "SEBL1STMF", "Close" ) ;
nu11 = Foreign( "ZAHINTEX", "Close" ) ;
 
AvgNewUncategorizedClose=(nu1+nu2+nu3+nu4+nu5+nu6+nu7+nu8+nu9+nu10+nu11)/11;
NewUncategorizedsmoother=MA(AvgNewUncategorizedClose,N);
if(NewUncategorized==1)
Plot(NewUncategorizedsmoother,"", ParamColor( "NewUncategorized Color", colorLightGrey ), ParamStyle("NewUncategorized Style", styleLine|styleNoLabel|styleThick|styleOwnScale, mask = maskAll) );
_SECTION_END();
 
 
_SECTION_BEGIN("");
Price=C;
priceplot=MA(Price,n);
Plot (priceplot,"", ParamColor( "Symble Color", colorCustom12 ), ParamStyle("Symble Style", styleLine|styleNoLabel|styleDashed|styleOwnScale, mask = maskAll) );
_SECTION_BEGIN("");
 
_SECTION_BEGIN("");
Title = StrFormat("\\c02 {{NAME}}.....{{DATE}}.....Open @ %g.....High @ %g.....Low @ %g.....Close @ %g.....Change = %.1f%%.... Volume = " +WriteVal( V, 1.0 ) +", {{VALUES}}",
O, H, L, C, SelectedValue( ROC( C, 1 )) )+
"\n"+
"\n"+ "\\c02 > > > Sector Price Analysis < < < "+
"\n"+EncodeColor(colorRed)+" Bank  ............................ @ " + Banksmoother +
"\n"+EncodeColor(colorYellow)+" Insurance .................... @ " + GeneralInsurancesmoother +
"\n"+EncodeColor(colorBrightGreen)+" Finance ....................... @ " + Financesmoother +
"\n"+EncodeColor(colorTurquoise)+" Engineering ................ @ " + Engineeringsmoother+
"\n"+EncodeColor(colorWhite)+" Textile .......................... @ " + Textilesmoother +
"\n"+EncodeColor(colorLightBlue)+" Fuel & Power ............. @ " + FuelPowersmoother+
"\n"+EncodeColor(colorPaleGreen)+" Cement ....................... @ " + Cementsmoother+
"\n"+EncodeColor(colorPink)+" Ceramics ..... .............. @ " + Miscellaneoussmoother +
"\n"+EncodeColor(colorLime)+" Pharma & Chemicals @ " + PharmaChemicalssmoother +
"\n"+EncodeColor(colorOrange)+" Food & Alied ............... @ " + FoodAliedsmoother+
"\n"+EncodeColor(colorTan)+" Tannery ....................... @ " + Tannerysmoother+
"\n"+EncodeColor(colorBlue)+" Mutual Fund ................ @ " + MFsmoother +
"\n"+EncodeColor(colorGold)+" Jute .............................. @ " + Jutesmoother +
"\n"+EncodeColor(colorAqua)+" Miscellaneous ........... @ " + Miscellaneoussmoother +
"\n"+EncodeColor(colorBrown)+" Services&Real Estate@ " + ServicesRealEstatesmoother +
"\n"+EncodeColor(colorViolet)+" Telecommunication . @ " + Telecommunicationsmoother +
"\n"+EncodeColor(colorPaleBlue)+" I T ................................. @ " + ITsmoother+
"\n"+EncodeColor(colorLightGrey)+" Travel & Leisure ........ @ " + TravelLeisuresmoother +
"\n"+EncodeColor(colorLavender)+" Paper & Printing ........ @ " + PaperPrintingsmoother +
"\n"+EncodeColor(colorSkyblue)+" Corporate Bond ........ @ " + CorporateBondsmoother +
"\n"+EncodeColor(colorLightGrey)+" New / Uncategorized @ " + NewUncategorizedsmoother;
_SECTION_END();
 
SetChartBkColor( 1 ) ;

7 comments

1. monirul islam

yes

2. Timon

thanks

3. deep_pocket

Sir where we can have the formula? thanks.

4. drnishikant

HID

5. vkb29

sir,
where i get AFL formula of this.

6. milkyblack

hi
from where can i get the AFL

7. mystock365

Is it possible to get the Afl ?

Leave Comment

Please login here to leave a comment.

Back