In this project, you nest INDEX and XMATCH functions to display information on the rental worksheet for Perfect Vacation Rentals. You create dynamic arrays for data, prepare time and date calculations, and use Text functions. File Needed: [your initials] Week09Practice01.xlsx Completed Project File Name: [your initials] Week09Practice02.xlsx Open [your initials] Week09Practice01.xlsx and save it as [your initials] Week09Practice02. Click the Days worksheet tab. Use the XMATCH function to show a property’s rank in total rental days. (Office 365/2021 Note: If XMATCH is not available, build the following MATCH function =MATCH(G2,A2:A25,0)). Select cell H2. The XMATCH function will match the value in cell G2 to cells A2:A25 and show in which row the property is located. Click the Lookup & Reference button [Formulas tab, Function Library group] and choose XMATCH. Select cell G2 for the Lookup_value argument. Click the Look_up array box and select cells A2:A25. Leave the Match_mode and Search_mode boxes empty. Match_mode defaults to an exact match and Search_mode defaults to first to last. Click OK. Chalet Soleil is number 1 in the array. Because the data in column C are sorted in descending order, this means that the property ranks at the top for number of days rented. Use the INDEX function to display the location name. Select cell H4. The INDEX function will display the related location name for the row number shown in cell H2. Click the Lookup & Reference button [Formulas tab, Function Library group] and choose INDEX. Select the first argument list array, row_num, column_num and click OK. Select cells B2:B25 for the Array argument. Click the Row_num argument box and select cell H2. The array is one column, so you need not enter a Column_num argument. Click OK. The location for Chalet Soleil is Bass Lake. Nest INDEX and XMATCH functions to display the number of days. (If XMATCH is not available, build the following nested function with MATCH =INDEX(A2:C25,MATCH(H4,B2:B25,0),MATCH(C1,A1:C1,0)). Select cell H6. Click the Recently Used button [Formulas tab, Function Library group] and choose INDEX. Select the first argument list and click OK. The INDEX function will display the data that is identified by the XMATCH function. Select cells A2:C25 for the Array argument. Because you have selected multiple columns, you will need both Row_num and Column_num arguments. Click the Row_num box, click the Name Box arrow, and choose XMATCH. Select cell H4, the result for the INDEX function. Click the Lookup_array box and select cells B2:B25. The result in cell H4 will be matched in this array. Leave the Match_mode and Search_mode boxes empty. Click the word INDEX in the Formula bar to display its Function Arguments dialog box. Click the Column_num box for the INDEX function. Click the Name Box arrow and choose XMATCH. Select cell C1, the label for the number of days column. Click the Lookup_array box and select cells A1:C1, the label row. Click the word INDEX in the Formula bar to display its Function Arguments dialog box (Figure 6-43). The formula is =INDEX(A2:C25,XMATCH(H4,B2:B25),XMATCH(C1,A1:C1)). The XMATCH arguments identify the first row, third column in the array, 354. Figure 6-43 XMATCH function nested in INDEX Click OK. Edit data to test the function. Select cell G2. This is the lookup_value argument for the XMATCH function in cell H2. Type Lazy Days and press Enter. Confirm the results in the data (Figure 6-44). Figure 6-44 Dynamic results for INDEX and XMATCH functions Use the UNIQUE function. Office 365/2021 Note: The UNIQUE function may not be available in all versions of Office 365 or Office 2021. Click the Lookup&Ref sheet tab and select cell G5. Click the Lookup & Reference button [Formulas tab, Function Library group] and choose UNIQUE. Select cells C5:C28 as the Array argument. The structured reference name is Table1[State]. Click the By_col box. The default argument is FALSE or omitted to look at the data row by row. Leave the By_col and Exactly_once arguments empty. Click OK. The result array lists eight state abbreviations. Use the SORT function. Office 365/2021 Note: The SORT function may not be available in all versions of Office 365. Select cell I5. Click the Lookup & Reference button [Formulas tab, Function Library group] and choose SORT. Select cell A5:A28 as the Array argument. The structured reference for the column includes the table and column names. Click the Sort_index box. Leave this box empty to sort by the rental name column. Leave the Sort_order and By_col arguments empty to accept the default settings. Click OK. The result array lists the property names in alphabetical order (Figure 6-45). Figure 6-45 UNIQUE and SORT results Use the FILTER function. Office 365/2021 Note: The FILTER function may not be available in all versions of Office 365. Select cell L4 and type ky. This cell will be used as criteria and is not case sensitive. Select cell K5. Filtered results will start in this cell. Click the Lookup & Reference button [Formulas tab, Function Library group] and choose FILTER. Select cell A5:C28 as the Array argument. These three columns will display in the filtered results. Click the Include box and select cells C5:C28. This is the column used to filter the data. Type = and click cell L4. This statement, when true, will find results in which the state is Kentucky (Figure 6-46). Figure 6-46 FILTER arguments Click OK. Three properties in Kentucky are listed. Observe dynamic array behavior by editing source data. Select cell A21, type Past History, and press Enter. The sorted property names in column I update. Select cell C9 and type OH for Ohio. Nine unique state names display in column G. Select cell L4 and type tn for Tennessee (Figure 6-47). Format dates and calculate years as a client. Click the Client&Dates sheet tab. Select cells C3:C25. These are serial numbers that represent dates. Click the Number drop-down list in the Number group [Home tab] and choose Short Date. Enter the TODAY function in cell A27. Select cell D3 and type =( to start a formula and enter the opening parenthesis. Click cell A27 and press F4 (FN+F4) to make the reference to today’s date absolute. Type − to subtract and click cell C3. Type )/ for a closing parenthesis and division. Type 365.25 to convert results to years and press Enter (Figure 6-48). Your results for this column are volatile and will not match results in this text. Figure 6-48 Calculate years as a client Copy cell D3 to cells D4:D25 without formatting to preserve borders. Format cells D3:D25 with the Number format to set two decimal places. Use WEEKDAY to determine the day of the week. Select cell E3. The formula will determine the day of the week for the client’s first inquiry. Click the Date & Time button [Formulas tab, Function Library group] and select WEEKDAY. Click the Serial_number entry box and select cell C3. Click the Return_type entry box. Leave the box empty to use the default (Figure 6-49). Figure 6-49 WEEKDAY function Press Enter. The result is 1 for Sunday. Copy cell E3 to cells E4:E25 without formatting to preserve borders. Select cells E3:E25, click the Number launcher [Home tab, Number group], and choose Custom as the category. Find and click a date format. Click the Type box and edit the format to display dddd. Click OK. The dddd format spells out the day name. AutoFit column E. Use WORKDAY to determine eligibility dates. Select cell F3. Click the Date & Time button [Formulas tab, Function Library group] and select WORKDAY. Click the Start_date entry box and select cell C3. Click the Days entry box and type 360. This sets one year (360 days) as the VIP eligibility criteria. Leave the Holidays box empty. The Function Arguments dialog box previews the result as a serial number (Figure 6-50). Figure 6-50 WORKDAY function Click OK. Copy cell F3 to cells F4:F25 without formatting to preserve borders. Select cells F3:F25 and apply the Short Date format. Calculate time. Click the CleanTime sheet tab. Select cell D4. Type =( to start a formula with the left parenthesis. Click cell C4, the end time. Type − to subtract and click cell B4, the start time. Type )* for a closing parenthesis and multiplication. Type 24 to convert days to hours. Type *60 to convert hours to minutes (Figure 6-51). Figure 6-51 Calculate time as minutes Press Enter. The result displays as 12:00 AM. Format the result as General from the Number Format list [Home tab, Number group]. Copy cell D4 to cells D5:D9 without formatting to preserve borders. Nest the UPPER and REPT functions. Select cells B12:C14 and click the Merge & Center button [Home tab, Alignment group]. These cells are blank. Select cell B12, the blank merged cell. Click the Text button [Formulas tab, Function Library group] and select REPT. Click the Text entry box. You will nest the UPPER function for this argument. Click the Name Box arrow and select UPPER. (If UPPER is not in the list, click More Functions and navigate to and select UPPER from the Text category.) Type “Welcome to PVR!, press Spacebar two times, and type the closing quotation mark (”) after the spaces. This is the Text argument for the UPPER function. Click REPT in the Formula bar to display the REPT Function Arguments dialog box. Click the Number_ times box and type 3 to repeat the uppercase label three times (Figure 6-52). Figure 6-52 Nested UPPER and REPT functions Click OK. The results are centered at the bottom of the merged cell. Click the Wrap Text button [Home tab, Alignment group]. Save and close the workbook (Figure 6-53).