Excel数据分析与业务建模_第四章_匹配函数MATCH(语法详解及应用实例)

如果有一天,EXCEL中没有了LOOKUP函数,怎么办?答案是就靠MATCH和INDEX两兄弟了。

MATCH函数可返回指定区域内指定内容所在的行号(纵向区域)或列号(横向区域)。

Suppose you have a worksheet with 5,000 rows containing 5,000 names. You need to find the name John Doe, which you know appears somewhere (and only once) in the list. Wouldn’t you like to know of a formula that would return the row number that contains that name? The MATCH function enables you to find the first occurrence of a match to a given text string or number within a given array. You should use the MATCH function instead of a lookup function when you want the position of a number in a range rather than the value in a particular cell. The syntax of the match function is:
Match(lookup value,lookup range,[match type])
In the explanation that follows, assume that all cells in the lookup range are in the same column. In
this syntax:
■ Lookup value is the value you’re trying to match in the lookup range.
■ Lookup range is the range you’re examining for a match to the lookup value. The lookup range must be a row or column.
■ Match type=1 requires the lookup range to consist of numbers listed in ascending order. The MATCH function then returns the row location in the lookup range (relative to the top of the lookup range) that contains the largest value in the range that is less than or equal to the lookup value.
■ Match type=–1 requires the lookup range to consist of numbers listed in descending order.
The MATCH function returns the row location in the lookup range (relative to the top of the lookup range) that contains the last value in the range that is greater than or equal to the lookup value.
■ Match type=0 returns the row location in the lookup range that contains the first exact matchto the lookup value. (Chapter 19, “COUNTIF, COUNTIFS, COUNT, COUNTA, and COUNTBLANK functions,” discusses how to find the second or third match.) When no exact match exists and match type=0, Excel returns the error message #N/A. Most MATCH function applications use match type=0, but if match type is not included, match type=1 is assumed. Thus, use match type=0 when the cell contents of the lookup range are unsorted. This is the situation you usually face.

应用实例:

给出一个投资收益表,如何查找投资回报期(累积收益大于等于累积投资)。


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
对面向开发者的干货内容进行了梳理和总结: 一是理论。 过去一年间, AI 科技评论不断报道与人工智能技术相关的公开课程, 请来多个相关领域的资深学者, 持续解读基础概念, 为大家答疑解惑。 该栏目涵盖深度学习以及相关应用和延伸, 涉及自动驾驶、 语音、医疗、 人脸识别等方方面面。 二是工具。 AI 科技评论也在时刻关注着相关深度学习工具的动态和更新,如 TensorFlow、PyTorch、 Theano 等。 不仅如此, 我们还推出相关实战课程, 例如如何搭建系统进行图像识别。 除了底层工具,我们还关注大大小小的开源项目, 如 OpenBLAS、 阿里 Pouch、中科院 MatchZoo 等。 此外, 这一栏目也集结了腾讯、 阿里、英特尔等公司的深度学习解决方案。 三是赛事。 在与人工智能相关的一系列比赛中, 也能见到 AI 科技评论报道的身影。2017 年,我们对多个数据科学类的比赛进行跟踪报导, 涵盖 KDD Cup、 ICCV 2017 COCO&Places; 挑战赛、 DARPA 挑战赛、 京东金融全球数据探索者大赛等, 内容覆盖冠军解决方案、 赛事难点等多个层次, 冠军团队包括微软、 旷视等多家企业,清华大学、北京大学等多所高校。 希望大家能通过「理论」、「工具」、「赛事」 这 3 个栏目、 50 篇文章, 不断进阶,不断思考, 从理论走向实践, 成为一名优秀的开发者, 为人工智能社群贡献自己的一份力量。 也希望, AI 科技评论的这份总结和梳理能帮助到读者朋友们, 大家都能真正学有所获。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值