PureBytes Links
Trading Reference Links
|
> i want to create my own index.... and i want to weight the individual
> components eg
> heating oil at ummmmmmmm say 40%
> crude oil at 30%
> DAX at 30%
Set up HO in Data1, CL in Data2, DAX in Data3.
Now you could simply combine them by plotting (however you like):
0.40*Close of Data1 + 0.30*Close of Data2 + 0.30*Close of Data3
But that doesn't take their widely varying prices into account,
so e.g. CL (at about $35) will have almost 40x larger impact than
HO (at about $0.90). So you might want to scale them somehow,
maybe something like:
{ Get recent average value }
HO = Close of Data1;
CL = Close of Data2;
DAX = Close of Data3;
HOavg = average(HO, 100);
CLavg = average(CL, 100);
DAXavg = average(DAX, 100);
Index = 0.40*(HO/HOavg) + 0.30*(CL/CLavg) + 0.40*(DAX/DAXavg);
...or whatever calculation suits your fancy.
Gary
|