Open In App

Array Formulas in Excel

Last Updated: 14 Feb, 2023
Summarize
Comments
Improve
Suggest changes
Like Article
Like
Share
Report
News Follow

Excel is among the most powerful and widely used spreadsheet tools which eases organizing numbers and data within the sheets with pre-built formulas and functions. In this article, we are going to study Array Formulas. Arrays are one of them. Using Excel Array Formulas, make it super easy to handle a lot of data. Before understanding and using the Array formulas, let’s first understand what is Array in Excel?

Array in Excel

An Array in Excel is the structure that holds a collection of data. These data can be in the form of numbers or texts. There could be an array of 1-D or 2-D as well in Excel. For example, the array of fruits in excel would be written something like this:-

{“Apple”, “Banana”, “Grapes”, “Guava”}

We can directly enter it into the sheet by selecting the cells where you want to enter the data and then writing the array preceded by an “=” sign.  After these press Ctrl+Shift+Enter. For example, let’s enter these values in cells A1 to D1.

Array-in-excel

 

The array created here is a horizontal array. You can also create a vertical array by changing the selected cells. You can create an array by specifying the starting and the ending positions, for example, if you wish to make an array of elements between A1 to F1 then you can write A1:F1. Now. let’s move to array formulas.

Array formulas

Array formulas enable to process of several values and give several outputs. In a simple world, it can do multiple calculations and reduce a lot of human efforts. In other words, we can say that it solves array calculations and give an array as output too. Let’s understand more of them with an example, of students with their test marks,

Sample-data

 

Here, we have used a formula to evaluate the result in the ‘Total’ field. For inserting the formula, click on the cell where you want to store the answer and write the formula. Now, let’s try to calculate the same for all students

Using-Array-formula

 

For calculating the total for all the students, select the field where you want to store them, now select the range, and insert the formula. Array formulas are available in every version of Excel, so you don’t worry about your excel version. There are hundreds of operations possible using array formulas, which we will discuss in this article later. But before proceeding let’s understand what is the need to use an array formula.

Why use an Array Formula?

Array formulas are to most powerful yet most easy-to-use calculation tools which could be used to perform complex calculations and take place of hundreds of formulas with a single formula. You can further specify conditions for the calculation of data. Not just calculations you can also count the chars in cells, add date, day, or time, and even pick random data. 

How to insert an Array Formula?

Before entering the Array formula fir of all we understand some important points about the Array formula:

  • After typing the formula you have to press keys CTRL+SHIFT+ENTER together. It will automatically change the normal formula into an array formula. 
  • If you manually type braces around the formula then it will not convert the formula into an array formula. You have to use CTRL+SHIFT+ENTER keys to convert the formula into an array formula.
  • Whenever you edit the array formula the braces will disappear automatically and you have to again press the combination of CTRL+SHIFT+ENTER keys.
  • If you forget to press the CTRL+SHIFT+ENTER keys then your formula will work as the normal formula.

Now let’s understand inserting an array formula.

Single Cell Array formula

Every array formula returns the result in either single or in multiple cells. So when an array formula returns its result in the single-cell then such type of formula is known as a single-cell array formula. Such types of formulas are SUM, AVERAGE, AGGREGATE, MAX, MIN, etc. Follow the following steps to use the single-cell array formula:

Step 1: Select the cell where you want to store the answer.

Step 2: Now go to the formula bar and write an “=” sign.

Step 3: Now to formulas (highlighted below), and select the operation you want to perform.

Single-cell-array

 

Step 4: Here we want to perform the sum operation. Click on sum and a new popup will open. Write the cells you want to perform the operation with.

Function-arguments

 

Multi-Cell Array Formula

If you wish to perform the same calculation with more cells then you can use the multi-cell formula. You can implement it in two ways. Functions like TRANSPOSE, TREND, FREQUENCY, LINEST, etc are used for the multi-cell arrays. Implement the formula in single-cell by following the above steps. Now, drag the selection up to the cells you want to implement the formula. Below is the implementation of doing that.

Multi-cell-array-formula

 

Alternatively,

Specify the range of cells and an operator between them. For example, =(B1:B7 + C2:C7) and press Ctrl+Shift+Enter. 

Operator-in-multi-cell

 

Excel Array Constants

Excel array contacts are a set of static values and can’t be changed. These values remain constant regardless of the operations performed on them. Now we will see how to create Array Constants in Excel and will perform different actions on them. There are three types of array constant available:

1. Horizontal or Row Array constant

A horizontal constant is present in a row. To create a horizontal constant we have to type multiple values separated by a comma in the enclosed braces. To enter a row array follow these steps below:

Step 1: Select the cells you want to work with.

Step 2: Go to the formula bar and start with an equal sign. 

Step 3: Now enter the array you want to create in braces {}, separated by commas(,). Ex:- ={1,2,3,4,5}

Step 4: Now press Ctrl+Shift+Enter.

Horizontal-or-Row-Array-constant

 

2. Vertical or Column Array

Vertical array constants are generally present in Column Array. To create a vertical constant we have to type multiple values separated by a semicolon in the enclosed braces. To enter a column array follow these steps below:

Step 1: Select the cells you want to work with.

step 2: Go to the formula bar and start with an equal sign. 

Step 3: Now enter the array you want to create in braces {} separated with termination sign(;). Ex:- ={“Coding”;”GFG”;”GeeksforGeeks”}

Step 4: Now press Ctrl+Shift+Enter.

 Vertical-or-Column-Array

 

3. 2-D array

In Excel, you are allowed to create a 2-D array. So to create a 2-D array constant, we have to type multiple values in which rows are separated by semicolons and d columns are separated by commas. Let’s understand the implementation of a 2-d array. 

Step 1: Select the cells you want to work with.

Step 2: Go to the formula bar and start with an equal sign. 

Step 3: Now enter the array you want to create in braces {} separated with commas(,) for entering the values in same row, termination sign(;) for row change. Ex:- ={1,2,3;”Coding”,”GFG”,”GeeksforGeeks”}

Step 4: Now press Ctrl+Shift+Enter.

Working with Constant arrays

In the Excel formula, array constants are the important part. Some of the important concepts of Array constant are:

1. Elements: To create elements of array constant we have to follow the following points:

  1. The elements of an array constant must be of numeric, alphabetic, boolean, or scientific notation and each of them is separated by commas or semicolons.
  2. The elements of an array constant do not contain an array, cell reference, dates functions formulas, defined names, etc.
  3. You can also be allowed to use text in the array of the element but the text is surrounded by hyphens(“”). 

2. Naming Array Constants: You can name any array and use them as a variable for further references. For naming an array, follow the steps below:

  1. Go to the formula tab. and select Define Name.
  2. Write the array name in the name. You can also add some comments related to your array.
  3. Click on OK.

 

3. Common Errors: Following are the common errors that will happen while working with array constants:

  1. The use of delimiters in between the elements.
  2. The selection of range is also an important point to remember. 

Unary Operator in Excel Array Formulas

Using unary operators we can process the array using AND and OR operators. 

  1. AND: It is denoted by an asterisk(*) symbol. It returns true if and only if all conditions are true, 
  2. OR: It is denoted by a plus(+) symbol. It returns true if any of the statement is true.

These operators are more useful when you have the same variable with a different value. For example, let’s consider a case, where data of 3 sellers of different months are given and you have to how much Shyam sold potatoes.

Using-and-operator

 



News
Improve
Discuss
Do you want to advertise with us?Click here to know more

How to calculate Sum of Digits in a Number using Non Array Formulas in Excel?

In Excel, we can easily add the digits of a number. Usually, calculations that involve multiple values can be dealt with the help of array formulas, but here, we are going to find the sum of the digits of a number using non-array formulas. As an example, say we have a number 238 in one of the cells of the Excel sheet and we want to find the sum of the digits of this number. It would essentially be 2 + 3 + 8 which equals 13. Let us see how to do that without using an array formula. But before jumping on to the non-array formula method of finding the sum of the digits of a number, let us first see what is an array formula. Array FormulaAn array formula is nothing but a method that enables one to do multiple calculations at once. It can also do a calculation more than once in a specific cell range. Look at the example below. Say we have to find the product of quantities and cost as shown in the excel sheet below. If we do this using an array formula, then we can get the result much faster. We can use the multi-cell array formula for multiplying the quantity and cost column. Multi-cell array formula Here, we have to use a single formula and we will get results of all the rows. To cal
Read More

Dynamic Array Formulas in Excel

article_img
Dynamic arrays are resizable arrays that calculate automatically and return value into multiple cells based on a formula entered in a single cell. The new array (multiple cells) that we get is known as spilling and the new array has been placed in neighboring cells. It is not necessary to use Ctrl + Shift + Enter to enter an array formula. Dynamic array formulas are only available in Excel 365 and Excel 2021. Dynamic Array Formulas Below mentioned array formulas are the dynamic array formulas, let's learn in detail how these formulas are applied in excel on a certain dataset. UNIQUESORTSORT BYSEQUENCERANDARRAYFILTERLOOKUP UNIQUE Formula Unique formulas return a list of unique values in a list. Unique means that element that appears only once in an array. Values can be text, number, etc. A unique function is not case-sensitive means 'Apple' and 'apple' are the same. Syntax, =UNIQUE(A3:A17) fig 1. Print only Unique Values SORT Formula Sort formula returns a list in increasing order or decreasing order. Values can be text, number, etc. Syntax, =SORT(A4: A10) increasing order. fig 2. Sort the values SORTBY Formula SORTBY formula sorts the contents of a range based on values from
Read More

How to calculate Sum and Average of numbers using formulas in MS Excel?

article_img
Everyday in school, offices, business sectors or any other field lots of information are there that are required to store for future use. For anyone, it is very difficult to remember that information for a long time. Earlier data and information are stored in a form of a register, file, or by paperwork but finding it may be difficult for us. It takes a lot of time. To resolve this issue Microsoft brings a software called MS Excel. Microsoft Excel is a software that allows users to store or analyze the data in a proper systematic manner. It uses spreadsheets to organize numbers and data with formulas and functions. MS Excel has a collection of columns and rows that form a table. Generally, alphabetical letters are assigned to columns, and numbers are usually assigned to rows. The point where a column and a row meet is called a cell. Generally, it is used to keep records, data in various fields of business. Features of MS Excel Auto calculate: This helps you to calculate a group of data and it automatically shows the result in the status area You can also create your own formulas.Shared: You can share your data file over a network.Templates: It gives us a variety of elegantly designe
Read More

How to Lock Formulas in Excel

article_img
Are you tired of accidentally altering formulas in your Excel spreadsheets? Locking formulas in Excel is essential for maintaining the integrity of your data and ensuring that your calculations remain accurate. In this comprehensive article, you will learn the effective techniques to protect your Excel formulas from unintended changes, helping you keep your data secure. From understanding cell references to utilizing the $ shortcut for absolute references, we’ll cover everything you need to know. Whether you’re a beginner or an advanced user, mastering how to lock formulas will enhance your productivity and data management skills. Let’s get into the straightforward process of locking your Excel formulas and safeguarding your valuable calculations!In this article, we will discuss how to lock and protect the formulas within the Excel sheet along with an example.Lock Formulas in Excel Table of ContentUnderstanding Cell ReferencesHow to Lock Formula in Excel with Dollar Sign How to Lock Formulas in Excel Without Protecting the Workbook How to Lock Formulas in Excel shortcutHow to Remove Protection and Unhide Formulas in ExcelUnderstanding Cell ReferencesBefore we explore the $ shortcut
Read More

How to Show Formulas in Excel

article_img
Exploring the art of Excel formulas can turn up your data analysis and reporting capabilities. Whether you’re a financial analyst, digital marketer, or an Excel learner, understanding how to display formulas in Excel is important. This article will make you learn the simple steps to show the formulas of your Excel spreadsheets, enhancing your efficiency and proficiency. By learning how to show formulas in Excel, you’ll learn to ensure accuracy and transparency in your calculations. How to Show Formulas in ExcelHow to Show Formulas in MS Excel When you enter a formula in a cell and press the Enter key, Excel immediately displays the calculated result. To check all the formulas in the cell, follow one of the methods provided below for your reference, Show the Formulas Option on the Excel RibbonThe Ribbon: Head over to the Formulas tab, find the Formula Auditing section, and hit the Show Formulas button. Your formulas will step into the spotlight, replacing the results on stage. To get the calculated values back, click the Show Formulas button again to toggle it off. Go to Formulas Tab>> Select Show formulas Show Formulas in cells instead of their results in Excel optionsIn Exce
Read More

Basic Excel Formulas

article_img
Functions in Excel are the predefined formulas that have their specific meaningful work. They make our task easy and quick like finding the sum, count, average, maximum value, and minimum values for a range of cells. For example, the SUM function will calculate the sum of the range passed to it as an argument. Functions increase productivity while working in Excel. Basic Functions in Excel We have data on Vegetables used in 1 week in a house, and we find the total cost of vegetables. Now, we'll apply basic Excel Functions on the data. Sum(): It adds all the values in a range of cells. =SUM(C3:C8) will find sum of values given in the range from C3 to C8.Max(): It will find the maximum value in the given range of values.Max value from C5 to C12 is 80.Min(): It will find the minimum value in the given range of values.MIn value from C5 to C10 is 12.Average(): It calculates the average value in a range of cells.Count(): It will count the number of cells in a range of cells.Len(): It will return the number of characters in a string text.Sumif(): It Adds all the values in a range of cells that meet a specified condition. = SUMIF(range,criteria,[sum_range]).AverageIf():- It Calculates the
Read More

Top Excel Formulas and Functions You Should Know 2024

article_img
In the ever-evolving world of data analysis, mastering the top Excel formulas and functions is essential for maximizing productivity and efficiency. As we move into 2024, Excel remains a cornerstone tool for professionals across industries, from finance to marketing so for a better output you have to learn using Excel formulas. Whether you're a seasoned analyst or a beginner, exploring the excel formula list below will significantly boost your data handling capabilities.From the indispensable VLOOKUP and INDEX MATCH to the versatile XLOOKUP and FILTER, these formulas are designed to streamline your workflow and enhance data accuracy. Imagine effortlessly summarizing data with SUMIFS, managing conditional logic with IF and IFS, or performing complex calculations with ARRAYFORMULA. These essential Excel formulas are not just tools but gateways to smarter, faster, and more reliable data management.Table of ContentExcel Formulas vs FunctionsWhat is Excel FormulaWhat is an Excel Function How to Use Functions in ExcelHow to Use Formulas in ExcelDifference Between Formula and Functions in ExcelExcel Formulas and Functions with Examples1. Excel SUM Formula2. Excel SUBTRACTION Formula3. Exc
Read More

6 New Functions or Formulas in Excel 2019

article_img
A formula is a mathematical expression that computes a cell's value. Functions are predefined formulas found in Excel. Based on the values specified as arguments or parameters, functions perform specific calculations in a specific order. For instance, =SUM (C1:C10). This function adds the values from cells C1 to C10. In the math and trigonometry, statistical, engineering, date and time, lookup and reference, logical, and text function categories, several new functions are added. In addition, the Web category is introduced, along with a few Web service features. Some Basic functions in Excel were discovered earlier that can be used to perform basic operations. We also have a Statistical function in Excel that can be used in industries and businesses for better and more effective results. Categories of FunctionsExcel functions are classified according to their functionality. If you know the category of the function you're looking for, you can select it. Step 1: Select the FORMULAS tab. The group Function Library appears. The function categories are contained within the group. Step 2: Navigate to the More Functions tab. More function categories will be shown. Step 3: Select a funct
Read More

Excel Formulas not Working, not Calculating: Quick Ways to Fix Them

article_img
Microsoft Excel is a spreadsheet application that has been used by millions of people worldwide for more than three decades. Pivot tables, graphing tools, calculations, and a macro programming language are included. In contrast to other apps such as Word, spreadsheet software calculates values using mathematical formulas and data in cells. However, there are times when the Excel formulas do not work properly. These issues can arise due to various reasons, such as incorrect syntax, referencing errors, or data inconsistencies This article will assist you in fixing Excel formula issues helping you streamline your data analysis and improve productivity. How to Fix Excel Formulas Not WorkingIf an Excel formula is not working properly and returns an error or incorrect result. To fix it, follow the steps below: Problem: Change the Calculation Options from Manual to AutomaticIf you are unable to update the value you have input and it returns the same value, Excel's calculation option may be set to manual rather than automatic. Fix: Change the Calculation Option from Manual to Automatic Step 1: Open the spreadsheet that is giving you problems. Go to the Formulas tab, then select the Calcu
Read More

How to Use ChatGPT to Write Excel Formulas

article_img
Worrying about mastering Excel formulas? Thinking about the right syntax and function for hours? If you are, ChatGPT has got you covered! Discover how ChatGPT makes Excel formula writing effortless in the following article. In data analysis, Excel formulas reign supreme as a crucial tool. They make it possible to manipulate data, perform calculations, and uncover key insights. Unfortunately, for those new to the world of Excel, crafting formulas can feel intimidating and slow. Enter ChatGPT. With its AI capabilities, this language model is the perfect ally for any Excel formula writer, ensuring swift and efficient composition. Understanding Excel FormulasBefore we delve into how to use Chat GPT in Excel formulas, let's take a brief look at what Excel formulas for Chat GPT are and how they work. Excel formulas are expressions that are used to perform calculations or operations on data in an Excel worksheet. Syntax: Excel formulas follow a specific syntax either you're using it in general or for ChatGPT Excel. They always start with an equal sign (=), followed by the function name, arguments, and any other necessary operators. For example, the formula to add two numbers in Excel is =
Read More
three90RightbarBannerImg
  翻译: