I have three functions responsible for checking if I own a stock (by seeing that the column F is not empty) Then I want to check column AB to see what market the stock is from. In the first case I want to calculate the amount of Large Cap companies I own stocks in.
However my formulas seem to recalculate incorrectly. Sometimes they do not change at all when I add new owned stocks on my list. The following three functions are the functions I am using. (Keep in mind that it is European separators so the ";" should for example not be changed to ",".
=COUNTIFs(('ISK Investeringar'!$F$3:$F$103); "<>" ; ArrayFormula(vlookup(('ISK Investeringar'!$F$3:$F$103);sort({'ISK Investeringar'!$F$3:$F$103\'ISK Investeringar'!$AB$3:$AB$103};2;false);2;false)); "Large Cap" )/D3
=(COUNTIFs(('ISK Investeringar'!$F$3:$F$103); "<>" ; ArrayFormula(vlookup(('ISK Investeringar'!$F$3:$F$103);sort({'ISK Investeringar'!$F$3:$F$103\'ISK Investeringar'!$AB$3:$AB$103};2;false);2;false)); "Mid Cap") + COUNTIFs(('ISK Investeringar'!$F$3:$F$103); "<>" ; ArrayFormula(vlookup(('ISK Investeringar'!$F$3:$F$103);sort({'ISK Investeringar'!$F$3:$F$103\'ISK Investeringar'!$AB$3:$AB$103};2;false);2;false)); "Small Cap"))/D3
=COUNTIFs(('ISK Investeringar'!$F$3:$F$103); "<>" ; ArrayFormula(vlookup(('ISK Investeringar'!$F$3:$F$103);sort({'ISK Investeringar'!$F$3:$F$103\'ISK Investeringar'!$AB$3:$AB$103};2;false);2;false)); "First North" )/D3
With these 3 formulas and for example with 7 different stocks in the following markets:
Large Cap Large Cap Large Cap Large Cap ETF Mid Cap First North
I get the following percentages: 71% Large Cap 14% Mid Cap 0% First North
Can anyone see what is incorrect in this formula for the purpose described above. I have the same type of formula for looking at how many unique branches I own companies in and that function works perfectly. I will share that function below:
=COUNTIFs( UNIQUE('ISK Investeringar'!$C$3:$C$103); "<>"; ArrayFormula(vlookup(unique('ISK Investeringar'!$C$3:$C$103);sort({'ISK Investeringar'!$C$3:$C$103\'ISK Investeringar'!$F$3:$F$103};2;false);2;false)); "<>" )
So I would like to know why my first 3 formulas is not working correctly but the last one is.
Thanks in advance