This is my function which returns too many functions because of the last IF statement. Anyway to get it all in?
=IF(H2="AY",IF(C2>0,(C2/100)*1,1/(C2*-1)*1*100),IF(H2="HY",IF(F2>0,(F2/100)*1,1/(F2*-1)*1*100),IF(H2="T",0),-1)))
This is my function which returns too many functions because of the last IF statement. Anyway to get it all in?
=IF(H2="AY",IF(C2>0,(C2/100)*1,1/(C2*-1)*1*100),IF(H2="HY",IF(F2>0,(F2/100)*1,1/(F2*-1)*1*100),IF(H2="T",0),-1)))
Hi
Can you explain what you are trying to get for what variables. As the function doesn't work, I don't know what it is you are trying to achieve.
rylo
The function works if you just take out the last if statement. So the function evaluates cell H2 for 3 different values. If it returns any of the first two it grabs a value from another cell and the division and stuff calculates betting odds based off of the number it grabs. The last if statement is simple. It evaluates cell H2 and if it returns a "T" I just want it to spit out a 0
Last edited by nobodyukno; 01-17-2013 at 11:49 PM.
Hi
This calculates but I don't know if it does what you want.
=IF(H2="AY",IF(C2>0,(C2/100)*1,1/(C2*-1)*1*100),IF(H2="HY",IF(F2>0,(F2/100)*1,1/(F2*-1)*1*100),IF(H2="T",0,-1)))
rylo
This evaluates correctly, but I have noooo idea if it giving you what you need - test it...
=IF(H2="AY",IF(C2>0,(C2/100)*1,1/(C2*-1)*1*100),IF(H2="HY",IF(F2>0,(F2/100)*1,1/(F2*-1)*1*100),IF(H2="T",0,-1)))
the error was that the last if() had no "else do this" to it
1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
2. If your question is resolved, mark it SOLVED using the thread tools
3. Click on the star if you think someone helped you
Regards
Ford
With what you guys posted I am just getting false with no matter what I type. Let me break it down:
Evaluate H2 for the following:
AY - If yes, do this part of the formula: IF(C2>0,(C2/100)*1,1/(C2*-1)*1*100)
HY - If yes, do this part of the formula: IF(C2>0,(C2/100)*1,1/(C2*-1)*1*100)
T - If yes, put a 0
If False, meaning none of the preceding options, then put a -1
Maybe ...
=IF(H2="AY", IF(C2 > 0, C2/100, -100/C2), IF(H2 = "HY", IF(F2 > 0, F2/100, -100/F2), IF(H2 = "T", 0, -1)))
Are you trying to calculate the bet required to win a dollar based on betting line odds?
Entia non sunt multiplicanda sine necessitate
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks