当前位置:网站首页>Do you know all the wonderful functions of the vlookup function?
Do you know all the wonderful functions of the vlookup function?
2022-06-28 23:04:00 【CDA Data Analyst】
CDA Data Analyst Produce
author :CDA The star lecturer Cao Xin
edit :Mika
VLOOKUP The function is Excel A vertical search function in , It is associated with LOOKUP Functions and HLOOKUP Functions belong to a class of functions , It is widely used in work , For example, it can be used to check data , Functions such as importing data quickly between multiple tables .
that ,VLOOKUP What wonderful functions do they have ?
Today, I have summarized the following three things to teach you .
Master more VLOOKUP How to use the function ,
Please lock in the Tiktok live room at 8:00 tonight :【 Office software small class 】
01 VLOOKUP Accurate matching of http://mpvideo.qpic.cn/
The first application is precise matching , This is one of the most common methods we use to use it .
Here I have a table , It includes departments 、 full name 、 Education 、 Wages . This is also a table that we often encounter in our daily work .
Here we know the name of the case , I want to get someone's salary , We are going to have a look at vlookup How did you write it .
The first thing to do is =VLOOKUP , To wake up this function .
Next, the first parameter A13, That's what you're looking for , That is the name Wang Wu .
Next, we will mark the area to be searched , This area is from B2 To D10, That is, from Zhang San to 8000 This area , This whole area is the area we are looking for .
The third parameter 3 What does that mean? ? Is the value we want to return , The returned value is salary . Salary is the number one in this area 3 A place .
The last parameter is False, It represents precise matching , Of course, you can also write 0, So we need to write it down a little .
Here you may notice , Why is there a dollar sign $ Well ?
After writing a line, many students , I like to drag it down , Let it run automatically . But pay attention to the process of dragging , there 2 and 10 It is possible to follow the trend , But we don't want this table to change , Because Zhang San may not be in this table after the change , So I need a dollar sign $ hold 2 and 10 Fixed , You are always 2 and 10 In this area .
So we can get Wang Wu's salary 8000. I know the way , Let's use this formula to actually write .
=VLOOKUP, Then the value we want to find is that the region it wants to find is this region , The column to return is the third column , And what we want is precise matching , So it is false. And then go back , You get the result you want , On the ninth 1 Ten thousand yuan salary .
Here are a few points for attention :
The first point is , We must put the name we are looking for in the first column of the search area . If you don't put it in the first column , He can't find , This is what we use VLOOKUP It is very easy to make a mistake , That is to say, we must make sure that its area in the first column is the value we want to find , He can find .
The second thing to pay attention to is that we must make sure that the following is an accurate match false.
Sometimes some students say I don't know I can't remember , I will omit , When omitted, it also represents false Precise matching , But when we learn about approximate matching later , You may make mistakes , And you didn't find out , So I suggest you keep this piece in mind , In this case, my name must be accurate one-to-one correspondence , So I hope it is an exact match , So you must fill in here false perhaps 0.
This is it. VLOOKUP The most basic application , Have you learned to match accurately ?
02 VLOOKUP Approximate matching of
Next , What we need to learn is approximate matching .
We were using the VLOOKUP I often see , When the last parameter is used , Will let us choose true Or is it false.
We talked about false It's an exact match ,true It is called approximate matching , I never know what approximate matching means , Or what it feels like to actually use it .
Let me give you an example , Used to calculate our sales commission .
The table here contains the sales data of the salesperson , Zhang San 、 Li Si 、 Wang Wu … The sales volume of each row is different , I'll calculate their sales commission .
Please note that this column is for me VLOOKUP An approximate match .
What is the approximate matching method ? It is based on the percentage of this table .
It's easy for everyone to understand , You can see the percentage of commission in the table . If I use this ratio directly , Of course I'll go and see one by one by myself .
The other is that you use VLOOKUP, How to make a small transformation , Just turn it into the form on the right .
in other words , Put the minimum value of the previous range into the sales range .
Give Way VLOOKUP To do the so-called approximate matching , In fact, go to find the one closest to it .
Here we can write the formula , Its usage follows VLOOKUP The exact match before , But there is only one difference , That is, we should write the place of return as true.
=VLOOKUP, Start the function .
The first parameter B2 That's the value we're looking for , That is, the sales column .
Then where are we going to find it ?
It's in the red area , And I hope it doesn't move at all , No matter how long it takes , It is always in this area , So I want to put the dollar sign in front of the English and the numbers $.
When I drag the formula down after adding it , It is always in the red area and won't move , This is a point worth noting .
And the ratio I want to return is the second column , Because the first column uses sales to reduce , The sales volume is used for comparison .
Then the last one will add True, Approximate matching must be well written , Then run it for a while 3.
Let's drag it down again , Although I have already run , But we can still drag it , After dragging, we can get a result we want , This is the way to do approximate matching one by one .
It is different from precise matching , But it is also to help you understand in VLOOKUP When using approximate matching , What scene is it used in , Do you think of your actual work scene ?
03 VLOOKUP Reverse lookup
The following usage is very special , Reverse lookup .
I used to tell you , Use VLOOKUP Be sure to pay attention to the first column of the search range , It must be the value you are looking for , Otherwise you will not find .
But sometimes we just encounter such problems , For example, I still get this form , Department name 、 Education 、 Wages .
I know my name , Want to find out what his department is .
Many students said , Why don't you just move this department to the back of the name ?
This is the ideal situation , Sometimes we don't want to change our watches , I just use it temporarily in the process , What should we do at this time ?
This method tells you what to do , But it's a little complicated , You don't have to be afraid .
good , Let's try to write this function . First of all, I started =VLOOKUP.
Next A13 No problem , Is the name we are looking for Wang Wu .
I won't understand much later , I only remember the original VLOOKUP Let's write the scope of the search , But now I've written one by one if.
Let's not look at this , Let's take a look at the back , Will it .
The next one is to return to the second column .False, Precise matching .
good , Now we have only one question left , What exactly is this part ?
This is the table below . The effect is to turn the two columns upside down , Form such a table temporarily , Name and department .
Do you think it meets the requirements we need ?
The first name I want to find is in the first column , Then the value of the second column I want to return is just the Department . I'll just learn this function now .
It uses if function . uppercase IF, The first parameter to fill in is a brace plus 0 comma 1, What does it stand for ? You can understand it as 1 Show ,0 No display ; perhaps 1 Is the priority display ,0 Yes, and then , That is to say 1 than 0 Big .
Then the second parameter below is B2 To B10, It's actually the name . Notice that this position actually corresponds to a position of curly braces or curly braces .
Then the third parameter is A2 To A10, In fact, the value of department is placed in the third parameter , And its corresponding position is inside the curly brackets 0 This position .
It means , You have to put 1 The one in this position is B2-B10 Priority display , And then in A2 A10 In this position it corresponds to 0 Of , Next, it shows .
You can understand it this way , That is, if you write 1 and 0, After you write B2、B10、A2、A10, Will put the name first , Put departments behind , Then we get the result we want .
Now let's actually write it once . First =VLOOKUP .
Then the value we are looking for is OK , Week nine , And then the rest of it is finished . When I write this area , Just write if, Then brackets , Curly braces ,1 comma 0, I hope to be in 1 Priority display on this position , I want my name to appear first , Then the corresponding row is 0 The Department in this position , Show behind .
Then my region has actually been generated , Then I will return to the Department , That's the second column , Then you have to match them exactly , That is to say false.
B: no problem! , This formula is used , ad locum if The application of function is difficult to understand , But as I just said , You try and think , See if you can figure this out .
边栏推荐
- 手机办理股票开户安全性高吗?
- 一文搞懂shell脚本
- Linux Installation mysql5.7 (centos7.6) tutorial
- 一文读懂,WMS仓储管理系统与ERP有什么区别
- 运维排查-使用hcache插件排查Buffer/cache占用过高
- Realization of 2D code generation in micro build low code
- hiredis的代码示例
- 邂逅阿维塔 11:强产品力下久违的新鲜感
- Understand shell script in one article
- 【深度学习】(2) Transformer 网络解析,代码复现,附Pytorch完整代码
猜你喜欢

【深度学习】(3) Transformer 中的 Encoder 机制,附Pytorch完整代码

After crossing, she said that the multiverse really exists

How to use London gold to draw support resistance line

2022年PMP项目管理考试敏捷知识点(4)

第五章 虚拟存储器 练习
Sample code of using redis to realize the like function

Online text filter less than specified length tool

老家出资,俞敏洪设立两支基金

Wechat red envelope cover making tutorial and use guide with link jump

Basic knowledge diagram of K-line Diagram -- meaning of single K-line
随机推荐
Qtcreater5.15.0 source code compilation process record
Mono's execution process
Leetcode 324 swing sort ii[sort double pointer] the leetcode path of heroding
浅析搭建校园在线教学视频汇聚平台的必要性及解决方案
How to analyze the trend chart of London gold market with the moving average
直击产业落地 | 飞桨重磅推出业界首个模型选型工具
月薪6万,互联网“降本增效”后,这类人开始被疯抢
第五章 虚拟存储器 练习
自媒体行业内卷严重:企业自媒体应该何去何从
CS5463代码模块解析(包含下载链接)
Qsrand, srand random number generating function in qt5.15 has been discarded
Realization of 2D code generation in micro build low code
Is it safe and reliable to open a securities account in changtou school?
Wechat red envelope cover making tutorial and use guide with link jump
Interpretation of papers (DCN) towards k-means-friendly spaces: simultaneous deep learning and clustering
【Word 教程系列第 1 篇】如何去除 Word 表格中的箭头
Prometeus 2.36.0 new features
DBNN实验进展
[kotlin] beautiful pop-up box, custom pop-up box (dialog box), extension function, chrysanthemum waiting bar, message prompt box
Understand shell script in one article