COUNTIF funkcija u Excelu

[:sr]Kako se upotrebljava COUNTIF funkcija u Excel-u[:en]How to use the COUNTIF function in Excel[:]

[:sr]

COUNTIF funkcija u Excel-u

Počev od verzije: 5.0

Jedna od veoma značajnih verzija Excel-a je verzija 5.0 iz 1994. godine kada se pored VBA, PivotTable funkcionalnosti značajno proširio i skup funkcija, sada nama posebno interensantna COUNTIF funkcija u Excel-u koja je detaljno objašnjena na Office stranici za podršku korisnicima.

U mnogim slučajevima neophodno je prebrojati vrednosti u ćelijama koje ispunjavaju neki logički kriterijum.

Koristimo funkciju COUNTIF, jednu od statističkih funkcija za prebrojavanje ćelija koje ispunjavaju kriterijum.

Sintaksa

COUNTIF(opseg, kriterijumi)

  • Opseg (obevezan)- Grupa ćelija koje želimo da prebrojimo. Opseg može da sadrži brojeve, nizove, imenovani opseg ili reference koje sadrže brojeve. prazne i tekstualne vrednosti zanemaruju.
  • Kriterijumi (obavezan)- Broj, izraz, referenca ćelije ili tekstualna niska koja određuje koje ćelije će se prebrojavati. COUNTIF koristi samo jedan kriterijum. Ako želite da koristite više kriterijuma, upotrebite funkciju COUNTIFS.

Primeri upotrebe

COUNTIF je nešto složenija formula, koja može sadržati razne kriterijume. Konkretno u prvom primeru je to reč u ćeliji E6, sto znači da broji ćelije u kojima se nalazi tačno određena vrednost. U ovom slučaju reč Verovatno se pojavljuje pet puta i rezultat je 5. Formula je: =COUNTIF($E$6:$E$20;$E$6)

Drugi primer govori koliko ćelija ima vrednost veću od definisane (od broja 2). U suprotnom isto važi, ako koristimo znak manje, možemo da vidimo koliko ćelija ima vrednost manju od definisane. Formula je: =COUNTIF(B1:B7;”>2″) (rezultat je 5)

Primer sličan prethodnom je treći primer, samo što ovde možemo izbrojati vrednost koja je veća ili jednaka definisanoj. Kada je u pitanju manje ili jednako, procedura je ista. Formula je: Formula je: =COUNTIF(B1:B7;”>=2″) (rezultat je 7)

U pitanju je nesto složenija formula koja pokazuje koliko ćelija ima vrednost veću od dva, a manju od sedam. Formula je: =COUNTIF(B1:B7;”<7″)-COUNTIF(B1:B7;”<2″) (rezultat je 3)

U poslednjem primeru za funkciju Countif, pokazan je broj ćelija koje sadrže određenu reč. Znak zvezdice zamenjuje bilo koji drugi simbol. Zato možemo da ga kombinujemo sa drugim rečima. Na primeru na slici, mi brojimo svaku ćeliju koja sadrže reč izveštaj, bilo da je ona na početku, na kraju ili na sredini.

Napomena

Formula COUNTIF prima grešku #VALUE! kada upućuje na drugi radni list, ova greška javlja se kada formula koja sadrži funkciju upućuje na ćelije ili opseg u zatvorenoj radnoj svesci, a ćelije se izračunavaju. Da bi ova funkcija radila, druga radna sveska mora biti otvorena.[:en]

Excel COUNTIF formula

Appears from version: 5.0

One of the most important versions of Excel is version 5.0 from 1994, when, in addition to VBA, PivotTable functionality, the set of functions was also significantly expanded, now the COUNTIF function is particularly interesting to us, which is explained in detail on the Office page for user support.

In many cases, it is necessary to count values ​​in cells that meet some logical criterion.

We use the COUNTIF function, one of the statistical functions to count the cells that meet the criteria.

Syntax

COUNTIF(range, criteria)

  • Range (required) – The group of cells we want to count. A range can contain numbers, strings, a named range, or references that contain numbers. blank and text values ​​are ignored.
  • Criteria (required) – A number, expression, cell reference, or text string that specifies which cells to count. COUNTIF uses only one criterion. If you want to use more criteria, use the COUNTIFS function.

Examples of use

COUNTIF is a slightly more complex formula, which can contain various criteria. Specifically, in the first example, it is the word in cell E6, which means that it counts the cells in which the exact value is found. In this case the word Likely appears five times and the result is 5. The formula is: =COUNTIF($E$6:$E$20;$E$6)

The second example tells how many cells have a value greater than the defined value (of the number 2). Otherwise, the same applies, if we use the less than sign, we can see how many cells have a value less than the defined one. The formula is: =COUNTIF(B1:B7;”>2″) (result is 5)

An example similar to the previous one is the third example, only here we can count a value that is greater than or equal to the defined one. When it comes to less than or equal to, the procedure is the same. The formula is: The formula is: =COUNTIF(B1:B7;”>=2″) (result is 7)

It is a somewhat more complex formula that shows how many cells have a value greater than two and less than seven. The formula is: =COUNTIF(B1:B7;”<7″)-COUNTIF(B1:B7;”<2″) (result is 3)

In the last example for the Countif function, the number of cells that contain a specific word is shown. The asterisk replaces any other symbol. That’s why we can combine it with other words. In the example in the picture, we count every cell that contains the word report, whether it is at the beginning, end, or middle.

Remark

The COUNTIF formula receives an error #VALUE! when referencing another worksheet This error occurs when a formula containing a function references cells or a range in a closed workbook, and the cells are being calculated. Another workbook must be open for this feature to work.

[:]
4/5 - (4 votes)