Financial Spreadsheeting Week 1-12 Summary (Smt 2, 2023)

pdf

School

University of Toronto *

*We aren’t endorsed by this school

Course

470

Subject

Computer Science

Date

Oct 30, 2023

Type

pdf

Pages

63

Uploaded by UltraFireGorilla17

Report
FINANCIAL SPREADSHEETING LONG SUMMARY FOR FINAL EXAM SEMESTER 2, 2023
Table of Contents MICROSOFT EXCEL’S SUMMARY (WEEK 1 – 6) ............................................................................................ 4 I. IMPORT DATA .................................................................................................................................. 4 1. Importing real-time stock data .................................................................................................... 4 2. Importing ASX companies’ stock historical data of from yahoo finance ...................................... 4 II. EXCEL FUNCTIONS ........................................................................................................................... 5 1. The NOW and TODAY Functions .................................................................................................. 5 2. The TEXT Function ....................................................................................................................... 6 3. The FORMULATEXT Function ....................................................................................................... 9 4. The SUM Function ..................................................................................................................... 10 5. The WORKDAY Function ............................................................................................................ 13 6. The WEEKDAY Function ............................................................................................................. 15 7. The DATEVALUE function ........................................................................................................... 16 8. The MATCH Function ................................................................................................................. 18 9. The OFFSET Function ................................................................................................................. 19 10. The SPILL Range Operator ..................................................................................................... 22 11. The INDIRECT Function .......................................................................................................... 23 12. The UNIQUE Function ........................................................................................................... 26 13. The ROW and COLUMN Functions ........................................................................................ 28 14. The IRR Function ................................................................................................................... 29 15. The NPV Function .................................................................................................................. 30 III. ASX TRADING DAYS ................................................................................................................... 35 1. Create an ASX trading day list .................................................................................................... 35 2. Derive a historic span from the ASX trading day list .................................................................. 37 IV. OTHERS ......................................................................................................................................... 40 1. Defining Names ......................................................................................................................... 40 2. Referencing in Cells ................................................................................................................... 45 3. Create a Chartsheet .................................................................................................................. 48 4. What If Analysis ......................................................................................................................... 49 5. Add Features to Quick Access Toolbar ....................................................................................... 50 VISUAL BASIC APPLICATION’S SUMMARY (WEEk 7 -12) ............................................................................ 53 I. Basics ............................................................................................................................................ 53 1. Definitions/Abbrevations .......................................................................................................... 53
2. Shortcut Keys ............................................................................................................................ 53 3. VBE Interface ............................................................................................................................. 53 II. Procedures .................................................................................................................................... 56 1. Creating Sub Procedures ........................................................................................................... 56 2. Adding annotation .................................................................................................................... 56 3. Declaring and Assigning Variables ............................................................................................. 57 4. InputBox Function ..................................................................................................................... 58 5. In Built Dialog Boxes .................................................................................................................. 61 6. Create an NPV Function Procedure ........................................................................................... 61 III. Others ........................................................................................................................................... 63
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
MICROSOFT EXCEL’S SUMMARY (WEEK 1 – 6) I. IMPORT DATA 1. Importing real-time stock data 1) Ensure you are connected to internet. 2) Open an Excel workbook, and type any ASX code on the active cell (i.e. the cell you are highlighting). Example: type “WOW” (ASX code for Woolworths). 3) Go to “ data” tab, look for “Data types”, and click on the “stock” icon ( ). A dialog box will pop up on the right side of the excel workbook, showing all possible companies for “WOW”. 4) Select “Woolworths Group Limited”. 5) The “WOW” in the active cell will be replaced by “Woolworths Group Limited (XASX: WOW)”. 6) The following icon: will appear. Click on it and select any indicators to display them in real time manner: such as price, close price, and volume. 2. Importing ASX companies’ stock historical data of from yahoo finance 1) Open the web: au.finance.yahoo.com/quote/ inputASXcodehere ? .... 2) Click on “historical data” 3) Click on “time period” and set the time range (1D, 3D, 1M, 3M, 1Y, or custom) 4) Import the historical by downloading method or by query method as shown on the following tables: Step By downloading method By query method 1. On the “historical data” page, click on “download.” Right click on “download” on the “historical data” page .
Step By downloading method By query method 1. This will download the historical data as a csv file . Click on “Copy link address.” 2. Open the csv file with Microsoft excel. Open an excel workbook. 3. This will display the historical data table which consists of 7 columns : Date, Open, High, Low, Close, Adj. Close, and Volume. Click on “data” tab, look for the “Get & transform data” , and click on the “from web” icon ( ) . 4. The table is NOT automatically named. Paste the link address on the URL field and click “ Ok.” 5. Click Load if you want to display the data on a new worksheet. Click Load to if you want to display the data on an existing worksheet, and/or customize the output. 6. This will display the historical data table which consists of 7 columns : Date, Open, High, Low, Close, Adj. Close, and Volume. 7. The table is automatically named as “ the ASXcode. ” The range of the name will NOT include the titles of the columns. II. EXCEL FUNCTIONS 1. The NOW and TODAY Functions
1) The NOW function returns the serial number of today’s date AND time . 2) The TODAY function returns the serial number of today’s date ONLY . 3) No arguments needed for both functions. 4) Eventhough no arguments are needed, you MUST at least add the open bracket “(“ after “NOW” / “TODAY”. Otherwise, the functions will return a #NAME? error as follows: 5) You can customise the result’s format by using the TEXT Function . 2. The TEXT Function Returns a customised format of a numerical value / values from a single cell or an array . Function: =TEXT( value, format_text ) Where: Value : Fill it with a numerical value / values or a cell / an array containing numerical values or a formula that generates numerical values. Format_text : fill it with a customised format to our preference, Examples: 1) Add a dollar sign and two decimal digits to share price:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
2) Returns a long date value of a date: Please note that different letter’s numbers will generate different values ! For example, the A2 cell contains the serial number of 24 October 2023 . If you use TEXT Function on B2 cell to customised the date on A2, these are the possible results: No. Arguments of TEXT Functions Results 1 =TEXT(A2, ”d”) 24 2 =TEXT(A2, ”dd”) 24 3 =TEXT(A2, ”ddd”) Tue 4 =TEXT(A2, ”dddd”) Tuesday 5 =TEXT(A2, ”ddddd”) Tuesday 6 =TEXT(A2, ”m”) 10 7 =TEXT(A2, ”mm”) 10 8 =TEXT(A2, ”mmm”) Oct 9 =TEXT(A2, ”mmmm”) October
No. Arguments of TEXT Functions Results 10 =TEXT(A2, ”y”) 23 11 =TEXT(A2, ”yy”) 23 12 =TEXT(A2, ”yyy”) 2023 13 =TEXT(A2, ”yyyy”) 2023 3) Returns an ordinal number of a date by using combination of TEXT and VLOOKUP. Ordinal numbers are numbers with suffixes , such as 1st, 2nd ,3rd, and 4th. Example: Suppose you want to customise 24/10/ 2023 on B2 into 24th October 2023 on D2. The Arguments will be as follows: Important notes : a. You must add three double quotation marks (“””) before the “&” that intiates VLOOKUP and after the “&” that conclude the VLOOKUP. b. Carefully examine the table_array of the VLOOKUP function ! The table_array contains a manually inputted array instead of referencing to an array. It looks like this: {1,"st";2,"nd";3,"rd";4,"th";20,"th"} Manually inputted table-array has the following cahracteristics: (1) It begins and ends with curly bracket -> { }
(2) The commas ( , ) serves as a border between one column and the next column (3) The semicolons ( ; ) serve as a border between one row and the next row (4) If converted into a table, the manually inputted table_array will look like this 1 St 2 nd 3 rd 4 th 20 th c. Note that there was no number 24 on the table_array! In that case, the VLOOKUP will set the closest smaller value as the lookup value, which was 20. Only then it will return “th” from the second column. However , you MUST set [range_lookup] to TRUE (approximate match). Otherwise, the whole function will return an #N/A error. 3. The FORMULATEXT Function Returns Excel’s functions as text. Function: =FORMULATEXT (reference) Where: Reference : It can be a single cell or an array Examples: 1) FORMULATEXT function by using a single cell reference:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
2) FORMULATEXT function by using an array reference: 4. The SUM Function Returns the sum of a single cell with another cell, a single cell with an array, an array with an array, or all values in an array. Function : =SUM (number1, [number2], [number3], …) Where: Number1 : Can be a single cell,an array, or users can directly type a number in it. [number2] onwards : Same as number 1, but optional. Examples: 1) SUM a single cell with another cell :
2) SUM a single cell with an array : 3) SUM all values within an array : 4) SUM an array with another array :
5) SUM two intersecting arrays . Consider the following figure: C2:C4 intersects B3:D3. If you SUM both arrays (as the figure displayed), then all values in each array will be SUMmed first , then the SUM result of each array will be SUMmed together . The result is 6 as displayed: However , if you remove the delimiter (comma) between the two arrays on the function as follows: then the function will only SUM the intersecting cell(s) (i.e. C3). The result will be 1 as follows:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
5. The WORKDAY Function Returns the date of a working day after / before specific working days of another date. Function: =WORKDAY(start_date, days, [holidays]) Where: Start_date : fill in with the serial number of anchor date or reference that contains the anchor date Days : fill in with the number of days after the start date [holidays] : The square brackets indicate that this argument is optional. - Can be a single cell or an array that contains your customised dates of holidays Example : Suppose you typed Monday, 23 October 2023 on C2:
Then you want to know what is the working day date one working day after 23 October 2023. The function and the result will be: If you want to know what is the date of working day four working days after 23 October 2023, the function and the result will be: If you want to know what is the date of working day four working days after 23 October 2023 AND 24 October 2023 is holiday, the [holiday] argument must refer to the cell that contains 24 October 2023. the function and the result will be: If you want to know what is the date of working day four working days BEFORE 23 October 2023, simply add a minus before 4 on the days argument. The function and the result will be:
6. The WEEKDAY Function Returns the sequencial numbers of dates Function: =WEEKDAY (start_date,[return_type]) Where: start_date : the date reference. - Can be one or series of the serial number of dates. - Can be a single cell or an array containing serial number of dates [return_type] : Optional. - Fill with one of the following numbers (please memorise): 1,2,3 or 11,12,13,14,15,16,17 - If empty / omitted, the return_type will automatically be set to 1. Examples: 1) Return the sequencial number of a date in a single cell:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
2) Return the sequencial numbers of dates in an array: 7. The DATEVALUE function Returns the serial number of a date/dates from the string of the date(s). Function: =DATEVALUE( date_text ) Where: Date_text : fill it with text string of the date(s) or with the A1 format of single cell or an array containing the text string(s) of the date(s). Examples: 1) Returns the serial number of a date from a single cell containing the string of the date :
2) Returns the serial number of a date by typing the string of the date directly on the function arguments dialog box: 42095 = 1 Apr 2015 3) Returns the serial number of dates from an array containing the strings of the dates :
8. The MATCH Function Returns the position number of a value in a cell relative to the array it belongs. Function: =MATCH (lookup_value, lookup_array, match_type) Where: Lookup_value : can be a single cell , a one-column array , or a one-row array. Lookup_array : can be a one-column array or a one-row array. [Match_type] : The square brackets indicate that this argument is optional - Fill it with 1 , 0 , or -1 (Use 0 for the exact match of the value) Example s
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
1) MATCH Function if the lookup_array is a one-column array : 2) MATCH Function if the lookup_array is a one-row array : 9. The OFFSET Function Returns values of custom range based on a reference, given the number of rows and columns. Function: =OFFSET( reference, rows, cols, [height], [width]) Where: Reference : the reference from which you want to derive the offset. rows : the row by which the offset starts ( the row count starts from 0 , NOT 1 !).
cols : the column by which the offset starts (the column count starts from 0, NOT 1! ). [height] : The number of rows you want to display from the reference. The square brackets indicate that It is optional. If omitted/empty, the offset function will assume that you use the reference’s height. The height count starts from 1 . “0” height will return a #REF! error. A positive height will display values from the starting row downward. A negative height will display values from the starting row upward. [width] : The number of columns you want to display from the reference. The square brackets indicate that It is optional. If omitted/empty, the offset function will assume that you use the reference’s width. The width count starts from 1 . “0” width will return a #REF error. Width can only be positive. It will display values from the starting column to the right. Negative width, starting from -2 , will return a #REF! error. -1 width is deemed as equal with 1 width Example : Suppose there is an array containing dates from 23 October 2023 to 31 October 2023 :
And you want to return the values of the last five dates of the array. It means you want to display 27, 28, 29, 30, and 31 October 2023 . The arguments will be Reference : C2:C10 Rows : 4 (as 27 Oct 2023 is on row 4) Cols : 0 (as the only column is counted as 0) [height] : 5 (as you only want to return the values of five dates) [Width] : 1 (as all values are contained in one column) The function and results will be:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
10. The SPILL Range Operator You can use Hash (#) to return values from a one column-reference by just using the top cell . For example, you want to return the date values of B3 to B12 on D3 as follows : All you need to do is type =B3# (immediately add hash following the B3) on D3 :
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
The results: HOWEVER , the hash will only work in specific conditions, one of them is if the values from B3 to B12 were the result of an OFFSET function . Otherwise, adding hash will return a #REF! error. 11. The INDIRECT Function Returns values from a reference by using a text string as the reference. Function:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
=INDIRECT (Ref_text, A1) Where: Ref_text : The reference. The reference can be in three different forms , i.e. - the defined name of the reference (a single cell or an array). - the A1 format of the reference (a single cell or an array). - the R1C1 format of the reference (a single cell or an array). R stands for “Row”, and C stands for “Column.” A1 : A boolean. - Leave it empty or fill it with “TRUE” or “FALSE”. - This argument is only mandatory if you use reference with R1C1 format , where you MUST fill it with “FALSE”. Otherwise, it will return a #REF ! error. Examples: 1) Suppose you want to return the value of B3 (i.e. 26/10/2020) on F3: The INDIRECT function allows you to do it in three ways .
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
The first one is by using to the defined name of the reference (i.e. “Anchor”) that was provided in D4. Type “=INDIRECT(D4)” on F3 as follows: The second one is by using the A1 format as follows: And the last one is by using R1C1 format as follows:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
2) Now you want to return the all of the date values. It means the text_reference argument will represent an array of B3 to B12. The functions will be as follows: 12. The UNIQUE Function Returns unique values from an array. Function:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
=UNIQUE (array, [by col], [exactly_once]) Array : The reference. Can be in A1 format or defined name of the reference. [by col] : A boolean. Optional. - Type “TRUE” to identify unique columns (default) - Type “FALSE” to identify unique rows [exactly_once] : A boolean. Optional. - Type “TRUE” to identify values that only appear once - Type “FALSE” to identify every distinct values (default) Example: Identifying unique rows that only appear once: Identifying unique columns that only appear once:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
13. The ROW and COLUMN Functions 1) The ROW Function returns the row number of a single cell or an array. It only needs one optional argument, which is the [reference] . Example: If the [reference] is empty , the ROW function will automatically return the active cell’s row number as follows: 2) The COLUMN Function returns the column number of a single cell or an array. It only needs one argument, which is the reference . Example:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
If the [reference] is empty , the COLUMN function will automatically return the active cell’s column number as follows: 14. The IRR Function Returns the internal rate of return (IRR) for a series of Cash Flows. Function: =IRR( values,[guess] ) Where: Values : An array containing the series of cash flows. - The series of cash flows must be logical in relation to cash flows movement , i.e.: initial cash flow must be negative (indicates expenditure for project investment) and followed by positive cash flows (indicate the returns on investment)
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
[Guess] : Optional. Fill it with your own guess on the IRR result. - This argument, filled or not, will NOT affect the actual result of the function. Example: Suppose you want to know the IRR of the following series of cash flows from B4 to B9: The IRR Function will be as follows: 15. The NPV Function Returns the Net Present Value from a series of cashflows .
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
Function : =NPV( rate, value1,[value2], [value3] ) Rate : fill in with a single cell containing the market interest rate , or - directly type in the market interest rate on the Function argument. Value1 : a single cell containing a cash flow or - an array containing a series of cash flows [Value2] : Optional. - NOT needed if all cash flows are already referenced on the value1 argument . IMPORTANT : The NPV Function on Excel is misleading! Normally, NPV’s calculation takes into account : The Cash Flow Now (an expenditure that only occurs once in the beginning), and All Future Cash Flows (the number of future cash flows depends on the period numbers) However, The NPV Function on Excel doesn’t take the Cash Flow Now into account ! The first Cash Flow’s value you enter on the value1 argument will be treated as the future cash flow for the first period. Example: Investment A costs $100.000 . The investment is expected to generate positive cash flows for the next 5 years (as shown on the following table). The market interest rate
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
is 5%. You then want to know whether Investment A will generate a positive NPV, by using the following spreadsheet: Therefore: - Cash Flow for year 0 is Cash Flow now - Cash Flows for year 1 to 5 are Future Future Cash Flows for the next 5 years You then use the NPV Function to calculate the NPV of the investment as follows:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
And the result shows a negative NPV as follows: However, that is an incorrect result , because the NPV function actually treated the Cash Flow for Year 0 as the Cash Flow for year 1 . So, the NPV Function operated as if there are 6 periods of future cash flows, and NO initial cash flow. As a consequence, the result (- $12,771.87) misleadingly represents the present value (PV) of 6 periods of future cash flows , instead of representing the NPV of 5 periods of future cash flows.
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
The correct use of NPV Function will be as follows: Note that you took the Cash Flow for year 0 out of the argument and add it separately after the NPV Function ends . The result will be as follows: The NPV is still negative, but now it represents the correct NPV of Investment A!
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
III. ASX TRADING DAYS 1. Create an ASX trading day list Steps : 1) Determine time span . For example, the time span is year 2023 . It means that you will derive an ASX trading day list from 1 January to 31 December 2023 span. 2) Manually create an ASX holiday list on Excel Workbook. It means you must list all holidays in 2023 (Notes: Weekends are not included). It will look as follows: 3) Type the start date on a cell. As 1 January 2023 is a weekend ( Sunday ) , and 2 January 2023 is a holiday (New Year’s day), the start date of trading day list will be Tuesday , 3 January 2023 . 4) Just below the start date, use the WORKDAY Function.
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
Function: =WORKDAY (start_date, days, [holidays]) Where: Start_date : the start date, which in this example is 3/1/2023 on cell B9. Days : the number of non-weekdays and non-holidays after the start date. - Fill this argument with 1 if you want to make an ascending and consecutive trading day list. - Fill this argument with - 1 if you want to make a descending and consecutive trading day list. - In this example, we start from January 2023 which indicates it will be an ascending list, so fill it with 1. [holidays] : the square brackets indicate that this argument is optional - In this example, we use the table we have created at poin 2) as the reference - Make the reference absolute (by adding dollar signs) - Another way is by adding a defined name to the reference The function will be as follows (assume we use dollar signs for absolute reference):
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
5) Drag the function down until the date shows the last trading day in 2023. 6) You have succesfully created an ASX trading day list for 2023! 2. Derive a historic span from the ASX trading day list Suppose you are asked to analyse the stock movement in February 2023. You then can set the historic span by using the OFFSET Function . The steps are as follows:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
1) Determine the start date and the end date by looking at the ASX trading day list we have created before. In this case, the start date is 2 Feb 2023 and the end date is 28 Feb 2023 . 2) Determine the position / row number for both the start and the end dates. You can use the MATCH function as follows : Notice that there was a -1 after the MATCH Function? The -1 is mandatory as the counting of rows and columns in the following OFFSET function starts from 0. Therefore, we got the positions as follows: - The start date (1/2/2023) : 20
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
- The end date (28/2/2023) : 39 3) Determine the height between the start and the end dates. the height = 39 – 20 + 1 = 20 4) Insert the OFFSET function on an active blank cell. Ensure that 19 rows below the active cell is empty , otherwise the function will return a #SPILL error. The function will be as follows: =OFFSET($B$9:$B$260, 20, 0, 20, 1) $B$9:$B$260 = reference 20 = row position 0 = column position 20 = height 1 = width The results:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
5) Done! IV. OTHERS 1. Defining Names You can define a name for a cell , an array, or a customized function. Names are very useful for referencing. Defining a name can be done in 3 methods: 1) Defining a name for a cell / an array directly on the name box By default, the name bar shows the A1 format of the active cell as follows:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
To define the name of the active cell, simply type the wanted name on the name box and press enter. The result: It can be done for an array as well: 2) Create from selection You can use this method if the defined name is already stated alongside the array .
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
For example, you want to name the following dates array as “Dates”: Notice that there is already a title above the array named “Dates”. Block the title and the array as follows: Then click on “Formula” tab, look for “Defined names,” and click on “ Create from selection” :
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
The following dialog box will appear: Check the “top row” label, leave the rest empty, and click “Ok”. The array has been named.
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
3) Name manager Name manager can be used to name your own customised Excel’s functions , and is frequently used in complex referencing. For example, you want to name the SUM of the following array: Then click on “Formula” tab, look for “Defined names,” and click on “ Name manager” . The following dialog box will appear: Click on “ new” and the following dialog box will appear:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
Type “SumofNum” on the Name field, keep the Scope at “Workbook”, and replace the text on Refers to field with =SUM(sheet1!$B$2:$B$6) (Make sure you add the dollar signs!!). Click on “Ok”. Now you can call the named function on a blank cell. Please note that spaces are not allowed in defining a name. Use underscroll ( _ ) , period ( . ), or other symbols to connect between words in defining a name. 2. Referencing in Cells Referencing can be tricky! But basically, you can reference by two methods: 1) Referencing by using the A1 format of the reference’s cells. For example, you want to reference a table for a VLOOKUP function as follows:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
You simply typed C4:D9 on the [ lookup_array ] argument of the VLOOKUP function. If the reference table is on a different worksheet , you need to add the sheet name before C4:D9 as follows: The reference will be written as ‘Sheet1!C4:D9’. The sheet’s name usually occurs automatically when you set the reference. 2) Referencing by using the defined name of the reference’s cells. For example, you have set “Grades” as the name of reference table on the previous example. And you use that name for referencing as follows:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
You simply typed Grades (without the double quotation marks) on the [ lookup_array ] argument of the VLOOKUP Function. If the reference table is on a different woorksheet, you DO NOT need to add the sheet name before the reference table’s name as follows: However, if you set the defined name’s scope to only that particular Worksheet, then you NEED to add the sheet name before the reference table’s name as follows:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
The reference is written as “Sheet1!Grade.” You need to type the reference manually. 3. Create a Chartsheet Steps: 1) Right click on an existing chart that you are going to move into a chartsheet, and then click on Move Chart (See the following figure). 2) The following dialog box will appear. 3) Click on New sheet , rename the sheet if you wish, and then click OK.
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
4) You have succesfully created a Chartsheet. 4. What If Analysis You can access this Excel’s Feature by click on Data tab on ribbon, and highlight the Forecast group. Click on What If Analysis to display the following three features: 1) Scenario Manager Create a distinct scenario by setting one or more existing variables on Excel to certain values. 2) Goal Seek
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
Seek the value of a certain variable so the Excel’s formula produced our desired result. Elements of Goal seek is as follows: Set cell : MUST be filled with a cell address that contains formula To Value : : fill it with our desired result of the formula By changing cell : fill it with a cell address that is used in the formula on “Set cell” that you want to change. 3) Data Tables Change multiple variables to obtain possibility of multiple results. 5. Add Features to Quick Access Toolbar Steps: 1) Click on File: 2) Click on More , and then Options
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
3) A Dialog box will open. Click on Quick Access Toolbar and select the features that you want to add. For example, Camera. Click Add >> 4) Make sure you have checked the Show Quick Access Toolbar , and then click OK.
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
5) The camera tool has appeared on the Quick Access Toolbar
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
VISUAL BASIC APPLICATION’S SUMMARY (WEEk 7 -12) I. Basics 1. Definitions/Abbrevations VBA : Visual Basic Application VBE : Visual Basic Editor -> the place where you write codes All codes are written as procedures. There are two procedures: 1) Sub Procedures, or called Macros. 2) Function Procedures. They are used to create user defined functions . 2. Shortcut Keys Please note that VBE will only work on Excel files with xlsm extension (i.e. Macro-Enabled Worksheet). Several shortcut keys are : Alt + F11 : open the VBE (also used to close the VBE) Fn + F5 : run a Macro. Fn + F8 : show the step-by-step processes of a Macro. Ctrl + Break : Stop a running Macro. Useful to end a loop, but not applicable to all keyboards. Ctrl + G : Display the “Immediate Window.” Fn + F9 : Add a break point. Alt + I + M : Insert New Module Ctrl + F8 : Go to cursor. 3. VBE Interface 1) Ribbons Also known as toolbar .
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
- File contains save, import, export, print, remove module, and close the VBE. - Edit contains undo, find, replace, etc. - View contains Code, Projects explorer, Properties window, Locals, Window, Immediate Window, etc.. - Insert contains Userform, Module, etc. - Debug contains go to cursor, quick watch, etc. - Run contains Run, Break, Reset, and Design Code. Those are also displayed as icons right below the run tab. - Tools contains Macro, Options, etc. 2) Projects Explorer Window : Displays the name of Workbooks, Objects, Forms, and Modules.
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
3) Properties Window Displays the property of selected Objects, Modules, or Userforms 4) Codes Window This is where you write codes . In Module’s code , The top right combobox let you jump between procedures. In Userform’s code , The top left combobox let you generates or jump between procedures according to existing controls, while the top right combobox let you choose how to interact with those procedures. The bottoom left icons let you choose between Full Module or Procedures view.
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
5) Locals Windows Displays the step-by-step processes of running Sub Procedures / Macros. 6) Immediate Windows Displays debugging statement, such as debug.print. II. Procedures To create sub procedures and run them properly, you will need to construct complete instructions . Instructions consist of: creating sub procedures, creating and declaring variables, assigning variables/functions, and writing action statements. Examples of instructions as follows: 1. Creating Sub Procedures Type in: “Sub CreateSub” and press enter. The codes window will promptly display: Sub CreateSub() End Sub You have created a sub procedure. 2. Adding annotation
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
You can explain the codes by adding annotation by typing apostrophe (‘) and followed by the explanation. Example: Sub CreateSub() ‘ Create a sub procedure End Sub The annotation won’t affect macros, and is indicated by green font. 3. Declaring and Assigning Variables Variables need to be declared to avoid conflict within the sub procedures. Two ways of making variables declaration mandatory: 1) Manually type: Option Explicit At the very beginning of the codes window; or 2) Go to ribbons and click on tools > options and check the require variable declaration. Declarations are done by typing Dim before the variables. Variables don’t allow spaces . And you need to define the data types for the variables too. Examples of variable declaration: Declare variables as numerical values: Dim num1 as Byte ‘ smallest range of numerical data types Dim num2 as Integer ‘ does not allow decimal Dim num3 as Long Dim num4 as Single Dim num5 as Double Dim price as Currency ‘largest range of numerical data types Declare variables as text strings: Dim text as String Others:
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
Dim dte as Date Dim test as Boolean Dim var as Variant Declare variables as dynamic Dim Cashflows() as Double After declarations, you can assign variables to values, other variables, or functions . Examples: Num1 = 8 Num2 = Num1 Num3 = NPVCalc(Rate,Cashflows) Dte = #10/12/2023# Test = TRUE However, You need to redim Dynamic variables before assgining them . Example: Redim Cashflows (1 To 3) as Double Cashflows(1) = -3000 Cashflows(2) = 2000 Cashflows(3) = 1000 4. InputBox Function Two ways of initiating an input box: 1) The InputBox Function (Do NOT use this in exam!) The syntax: InputBox( prompt,[title],[default],[xpos],[ypos],[helpfile],[context] ) As String Weaknesses: - No errorhandler when error occurs
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
- Additionally, VBA’s input box cannot input range 2) The InputBox Method (Use THIS one in exam!) The syntax: Application.InputBox( prompt,[title],[default],[top],[left],[helpfile],[helpcontextID], [type] ) As String The [Type] argument represents the allowed input data type . It can be filled with the following numbers: 0 : A Formula 1 : A Number 2 : Text (a string) 3 : A logical value (True or False) 8 : A cell reference, as a Range object 16 : An error value, such as #N/A 64 : An array of values Examples : 1) InputBox by using number as input Sub InputBoxForNum() Dim StockPrice As Double Dim Test As Boolean Do StockPrice = Application.Inputbox(“Input Stock Price:”, _ “InputBox”,,,,,,1) If StockPrice < 0 or StockPrice = 0 Then
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
MsgBox “StockPrice must be positive”, vbCritical, _ ”Warning!” Else Test = True ActiveCell = StockPrice End If Loop until test End Sub 2) InputBox by using Range as input Sub InputBoxForRange() Dim rangeobject As Range On Error Resume Next Set rangeobject = Application.InputBox("Select Region", _ "Max", ActiveCell.CurrentRegion.Address, , , , , 8) If rangeobject Is Nothing Then Exit Sub Else MsgBox "maximum number is " & _ Application.WorksheetFunction.Max(rangeobject), vbOKOnly, _ "your result"
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
End If On Error GoTo 0 End Sub 5. In Built Dialog Boxes VBE allow you to pop up hundreds of Excel’s in-built dialogboxes: Syntax: Application.Dialogs(expression). show Example: create a macro to open up save as dialog. Sub OpenSaveAsDialog() Application.Dialogs(xlDialogSaveAs).Show End Sub 6. Create an NPV Function Procedure 1) The Function Procedure: Function NPVCalc(CFNow As Double, Cashflows() As Double, rate _ As Double) Dim t As Double Dim temp As Double Dim n As Double temp = 0 n = UBound(Cashflows)
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
If CFNow > 0 Or CFNow = 0 Then NPVCalc = CVErr(xlErrValue) MsgBox "CFNow must be negative" Else For t = 1 To n temp = temp + Cashflows(t) / ((1 + rate) ^ t) Next t End If NPVCalc = temp + CFNow Debug.Print "The value of NPVCalc is:" & NPVCalc Stop End Function 2) Macro for Testing the NPV Function Sub test_NPVCalc() Dim Ans As Double ReDim Cashflows(1 To 4) As Double Cashflows(1) = 4000 Cashflows(2) = 5000 Cashflows(3) = 6000 Cashflows(4) = 3000 Ans = NPVCalc(-10000, Cashflows, 0.05) End Sub
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
The answer should return 5,994.8042 III. Others GBM: dSt = μ St dt + σ St dWt Excel’s VCV Function =SQRT(MMULT(MMULT(C17:E17,C19:E21),TRANSPOSE(C17:E17))) Macaulay Duration: Cft x Dft x t Cft x Dft Cft = Cash Flow at time t Dft = Discount factor at time t T = time t
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help

Browse Popular Homework Q&A

Q: c) 1. BH3 2. H₂O₂, OH →
Q: A helicopter takes off from the roof of a building that is 175 feet above the ground. The altitude…
Q: How greatly did the Great Depression lead to the collapse of democracy in brazil?
Q: Proteins play many different and important roles in the body. Explain how all of the types of…
Q: NW 5.10 Consider the following probability distribution: Xx p(x) 0 -102 3 1 com 3 2 mean and the…
Q: Find the sum of the series 005 1. sum = e-2 2. sum = 4 3. sum = 5. sum = Σ (-1) ² n=0 e² 4. sum e…
Q: Write the equation for the ellipse with major axis of length 34 and foci located at (0,8) and (0,…
Q: What is the mass (in grams) of 9.43 x 1023 molecules of sucrose (C12H22O11)? First determine the…
Q: Define - Vectored Interrupts
Q: A sample of values taken from a normally distributed population are 6.8, 7.2, 5.4, 8.8 and 10.2. If…
Q: 1. What is the average speed of a skier, who travels 1200 meters downhill in 60.0 seconds? 2. In 5.0…
Q: What is the slope of the line perpendicular to the line whose equation is given by - 3y = - 6 x + 9?…
Q: Air with a density of 10 g/m^3 is 100% saturated at 12 C. At what temperature will it reach its dew…
Q: Suppose that you decide to buy a car for $32,635, including taxes and license fees. You saved $9000…
Q: There are n stacks of n identical-looking coins. All of the coins in one of these stacks are…
Q: Ali drove to the mountains last weekend. There was heavy traffic on the way there, and the trip took…
Q: Suppose that the search for key k in a binary search tree ends in a leaf. Consider three sets: A,…
Q: Suppose an economy produces steel, wheat, and oil. The steel industry produces $80,000 in rev- enue,…
Q: a. Use the appropriate formula to determine the periodic deposit. b. How much of the financial goal…
Q: 3.57 Consider the experiment depicted by the Venn diagram, with the sample space S containing five…
Q: A certain function f is given by the graph -8 50 Where are the horizontal asymptotes of f? 1. y = -3…
Q: In this discussion post, you will analyze actions taken by Edward Snowden; namely, where he was a…