Meo hay su dung ham D trong Excel

Tags: gia tri trung binh, Su dung ham, ket qua la, co the dung, dieu kien, tinh gia, tien luong, tieu chuan, lon hon, ban, cot, go, so, Excel


Meo hay su dung ham D trong Excel
Cach su dung vai ham D trong Excel
Ban thuong su dung mot so ham nhu SUMIF, COUNTIF va AVERAGE de cong, dem va tinh gia tri trung binh cua mot vung (range) theo mot tieu chuan (criteria) nhat dinh nao do.

Khi can tinh toan voi nhieu tieu chuan hon ban co the dung cong thuc day hay con goi cong thuc mang (array formula). De phan tich mot danh sach du lieu thoa nhieu dieu kien chon loc ban cung co the dung cac ham D.

Meo hay su dung ham D trong Excel, Tin tuc trong ngay, Ham D, Excel, thu thuat, SUMIF, COUNTIF

Sau day chung ta thu su dung cac ham DSUM, DCOUNT va DAVERAGE la cac ham “doi chieu” cua SUMIF, COUNTIF va AVERAGE. Cac ham D neu tren co dang: =DSUM(database,field,criteria), =DCOUNT(database,field,criteria) va =DAVERAGE(database,field,criteria). Trong do:

Database la khoi (Block) du lieu, o day la A1:B11 (gom ca tieu de cot).

Field la ten cot (Column), o day la cot “Luong” (co ca dau ngoac kep). Vi day la cot thu nhat cua khoi du lieu nen ban co the thay “Luong” bang 1 (so mot, khong co dau ngoac kep).

Criteria la pham vi khoi can ghi dieu kien chon loc, o day co the la D1:E2 hoac D1: E3 neu ban can thoa 2 dieu kien cua cung mot cot (cu them 1 dieu kien cua cung 1 cot thi them mot dong). Vi ham D tinh toan theo cot, nen tieu de cot cua Database va tieu de tuong ung cua Creteria phai giong nhau.

De tinh tong tien luong “lon hon 500.000”, ban go vao o D2: > 500000 va go vao o F2: =DSUM(A1:B11,”Luong”,D1:E2) hoac =DSUM(A1:B11,1,D1:E2). Ket qua la 9.500.000.

De tinh tong tien luong “lon hon 500.000” va “nho hon 300.000”, ban go them vao o D3: <300000 va go vao o F3: =DSUM(A1:B11,”Luong”,D1:E3). Ket qua la 9.800.000. Ban cung co the go cong thuc vua neu vao o F2 (thay vi F3), ket qua cung van la 9.800.000.

Neu de y ban se thay, khi khong dieu kien nao duoc nhap vao Criteria thi gia tri cua =DSUM(A1:B11,”Luong”,D1:E2) se bang gia tri cua =SUM(A2:A11), tuc la bang 11.200.000. Va neu ban chi nhap 1 dieu kien >500000 vao o D2 thi =DSUM(A1:B11,”Luong”,D1:E2) co cung gia tri voi =SUMIF(A2:A11,”>500000”) tuc la bang 9.500.000.

Meo hay su dung ham D trong Excel, Tin tuc trong ngay, Ham D, Excel, thu thuat, SUMIF, COUNTIF

Ban co the go them cac dieu kien vao cac o E2:E3. Thi du de tinh tong so tien luong cua nhung nhan vien co muc luong “lon hon hay bang 500.000 thuoc 2 phong A va phong B, ban go >=500000 vao 2 o D2 va D3 roi go A vao o E2 va B vao o E2. Ket qua o o F3 la 8.200.000.

Sau khi lam quen voi ham DSUM ban co the su dung ham DCOUNT de dem cac tri so trong cot luong lon 500.000 va nho hon 300.000. Ban se thay ket qua la 7. Ban cung co the dung ham DAVERAGE de tinh gia tri trung binh, thi du tinh tien luong trung binh cua nhung nguoi co muc luong lon hon 1.000.000. Ket qua la 2.633.333. Ngoai 3 ham D neu tren, ban co the thu voi cac ham D khac nhu DCOUNTA, DMAX, DMIN...

Nguyen Thanh
Viet Bao
Thích và chia sẻ bài viết này trên facebook Theo dõi vietbao.vn trên facebook
Tìm hiểu: gia tri trung binh, Su dung ham, ket qua la, co the dung, dieu kien, tinh gia, tien luong, tieu chuan, lon hon, ban, cot, go, so, Excel
Kinh nghiem
Kenh Tin RSS Kenh Tin RSS | Du Bao Thoi Tiet | Lich Xem TV | Lien He - Contact | Quang Cao | Viec Lam | Dieu Kien Su Dung | Bao Ve Tinh Rieng Tu | Sitemap

Copyright©2008 VietBao.vn, Thu Vien Thong Tin Tong Hop Viet Nam va The Gioi, phien ban thu nghiem phan mem Viet Bao Viet Nam, beta 1.0