Can anyone break down this formula for me pls

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.
Breaking it down

if(d4<>5 is saying if the cell D4 is not equal to 5 to perform countif(o$3:eek:3,">0")+1

countif(o$3:eek:3,">0")+1 is saying to count all the cells in that range that have a value of greater than 0 (basically all positives and to add 1
As you drag down the column will expand because
o$3:eek:3 row is locked at the third row. Because of the +1 the cell returned will have a minimum of 1.

,"-") if D4 is equivalent to 5 to put a "-" in the cell

another way to write is which is doing the opposite due to change of operater sign

=IF(D4=5,"-",COUNTIF(O$3:O3,">0")+1)

=if(d4<>5,countif(o$3:eek:3,">0")+1, "-")
 
Last edited:
Upvote 0
You could step through the formula and/or try Excel's Formula Evaluate.

If D4 is less than or greater than 5
then Count O$3:O3 and add 1

otherwise i.e. D4 is equal to 5 entry the "-"
 
Upvote 0

Forum statistics

Threads
1,203,465
Messages
6,055,574
Members
444,799
Latest member
CraigCrowhurst

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top