05-19-2015, 09:23 PM
hi,
to calculate MIRR (modified IRR) I need to divide list L1 in this way:
if L1(j) < 0 -> flneg(j), if L1(j) >=0 -> flpos(j)
with
in both lists there is 0 at the correspondent place in the other list (i.e. {-1, 2, 3, -4} -> {-1, 0, 0, -4} and {0, 2, 3, 0}
I need {-1, -4} and {2, 3}
please, help
TIA!
Salvo
to calculate MIRR (modified IRR) I need to divide list L1 in this way:
if L1(j) < 0 -> flneg(j), if L1(j) >=0 -> flpos(j)
with
Code:
FOR j FROM 1 TO size(L1) DO
IF L1(j) < 0 THEN flneg(j):= L1(j); ELSE flpos(j):= L1(j); END;
END;
in both lists there is 0 at the correspondent place in the other list (i.e. {-1, 2, 3, -4} -> {-1, 0, 0, -4} and {0, 2, 3, 0}
I need {-1, -4} and {2, 3}
please, help
TIA!
Salvo