on 05-30-2007 6:30 PM
Post Author: cmainard
CA Forum: Formula
Hi,
I wrote a simple "index return" formala, which seems to give me the proper result, but I'm hoping to get into the right format.
formula:
(2297.57/{@SP500Inception})-1 returns: 0.17
where @sp500inception value is equal to 1,958.49
I need it to return 17.31 ( %)
Any thoughts?
thanks!
Post Author: SKodidine
CA Forum: Formula
Two things you can do:
1. Multiply the whole thing by 100, such as ((2297.57/{@SP500Inception})-1) * 100
or 2. (2297.57 % @sp500inception ) - 100
To either one, add & "(%)" if you need the percent sign next to it.
Also, to prevent "a division by zero" error, you might want to check to see if {@SP500Inception} is not zero by adding;
if {@SP500Inception} = 0 then 0 else ONE OF THE ABOVE STATEMENTS.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.