Sie sind auf Seite 1von 11

QUICK GUIDE FOR THE 5 PRACTICE FILES

Note: There are usually more than one way to solve each question.

PRACTICE 1
A. Count sum
1. Use COUNTIF function.
2. Use COUNTIFS function.
3. Use COUNTIF function with wildcards in criteria.
4. Use COUNTIFS function for each range of revenue, then sum them.
5. Use COUNTBLANK function.
6. Use SUMIF function.
7. You can use SUMIF and COUNTIF functions, but remember that in HCMC
and Danang also means not in Hanoi, so you only need to use AVERAGEIF
function.
8. Use SUMPRODUCT function.
B. Logical
1. Use IF function.
2. Use IF and OR functions.
3. Use IF function in IF function (nested IF).
4. Its better to define names for cells and ranges to solve this question. To
define a name, open Formulas -> Name Manager. Click New button, set
Refers To the cell or range you want to be named, set Name any name you
want, then click OK. Or you can use Create from Selection button to
automatically define the name for your selected cells.
So heres the input: Position (LC, SC, LP, SP), Premium, Strike, NContracts
(number of contracts) and Price (it will be the horizontal axis of your
diagram).
And heres the output:
- Moneyness:

+ If Position = LC or SC, it will be In the money if Price > Strike, At


the money if Price = Strike, and Out of the money if Price < Strike
+ If Position = LP or SP, it will be In the money if Price < Strike, At
the money if Price = Strike, and Out of the money if Price > Strike
- CProfit (profit/loss per contract):
+ If Position = LC, CProfit = MAX (Price Strike Premium, - Premium)
+ If Position = SC, CProfit = - MAX (Price Strike Premium, Premium)
= MIN (Premium + Strike - Price, Premium)
+ If Position = LP, CProfit = MAX (Strike Price Premium, - Premium)
+ If Position = SS, CProfit = - MAX (Strike Price Premium, - Premium)
= MIN (Premium + Price - Strike, Premium)
- TProfit (total profit/loss): = CProfit * NContracts
Select both Price and TProfit column, then click Insert -> Line Chart -> Line.
The option profit diagram will be created.
C. Date and Time
1. Set format h:mmAM/PM d/mmm/yyyy
2. Use NOW function.
3. Use WEEKDAY function, or set format as dddd
4. We will define some names to help solving this question.
Input: YearInp (Year Input), MonthInp (Month Input).
Intermediate data: WeekdayInp (Weekday, from 1 to 7), WeekNoInp (Week
number, from 0 to 5).
To get the last Saturday of the previous month, we use this formula:
= DATE(YearInp,MonthInp,1)-WEEKDAY(DATE(YearInp,MonthInp,1))
So to get a day determined by WeekdayInp and WeekNoInp, we use this
formula:
=DATE(YearInp,MonthInp,1)-WEEKDAY(DATE(YearInp,MonthInp,1))
+WeekNoInp*7+WeekdayInp
Finally, you can use Conditional Formatting to grey out the days that not
belong to the current month.

PRACTICE 2
A. Format Cells
1. Set format 0.00000000000
2. Set format dd/mm/yyyy
3. Set format hh:mm
4. Set format Fraction
5. Use RIGHT function to get the number.
B. Find Replace
1. Use PROPER function.
2. Use Find dialog to search for * .
3. Use Replace dialog.
4. Use Go To Special -> Visible cells only to select visible columns.
5. Use Go To Special -> Formulas.
6. Find Th, Match entire cell contents.
7. Select Code column. Use Go To Special -> Blanks to select blank cells.
Right click -> Delete, choose Shift cells up, then click OK.
8. Select Tn & Tn 2 columns. Use Go To Special -> Row Differences.
C. Data Validation
1+4. Select A2, then open Data Validation:
- Allow: Whole number
- Data: Between
- Minimum: 2011
- Maximum: 2014
- Error Alert -> Style: Stop
2+5. Select A3, then open Data Validation:
- Allow: Custom
- Formula: =AND(WEEKDAY(A3)>1,WEEKDAY(A3)<7)
- Error Alert -> Style: Warning

6+7. Select A4, then open Data Validation:


- Allow: Custom
- Formula: =AND(ISTEXT(A4),LEN(A4)=5,RIGHT(A4,1)<>"X")
- Error Alert -> Style: Information
3. Select A5, then open Data Validation:
- Allow: List
- Ignore blanks In-cell dropdown
- Source: Hanoi, HCM City, Danang
D. Sort Filter
1. Select Tn column, choose Sort & Filter -> Sort A to Z.
2. Open Sort & Filter -> Custom Sort
- Add level: Sort by Tn A to Z.
- Add level: Then by Code Smallest to Largest.
3. First, create 2 columns:
- I column: header Random, formula: =RAND()
- J column: header Rank, formula: =RANK(I2,$I$2:$I$12)
Then use VLOOKUP (look up Rank in STT) to create auto-shuffle columns.
4. Select any column -> Sort by color.
5. Select Tn column -> Text Filters -> Begin with Input N, then click OK.
6. Select Code column -> Number Filters -> Greater than Input 100, then
click OK.
7. Select H column -> Text Filters -> Equals Input Nguyn, then click OK.
Select Code column -> Number Filters -> Greater than Input 200, then click
OK.
8. Sort Vng column A to Z, then open Data -> Subtotal
- At each change in: Vng
- Use function: Sum
- Add subtotal to: Doanh s
E. Conditional Formatting

1. Select Doanh s column, then open Conditional Formatting -> Highlight


Cell Rules -> Less Than Input 20000, set the format you want, then click
OK.
2. Select Doanh s column, then open Conditional Formatting -> Top/Bottom
Rules -> Above Average Set the format you want, then click OK.
3. Select Doanh s column, then open Conditional Formatting -> Highlight
Cell Rules -> Duplicate Values Set the dropdown to Duplicate, set the
format you want, then click OK.
4. Select table (excluding header), then open Conditional Formatting -> New
Rule... Select Use a formula to determine which cells to format, then input
this formula:
=MOD(ROW(A2),2)=0
Set the format you want, then click OK.
5. See Question 3 Sort and Filter to know how to shuffle Tn 2
Select Tn & Tn 2 columns, then open Conditional Formatting -> Highlight
Cell Rules -> Duplicate Values Set the dropdown to Unique, set the format
you want, then click OK.

PRACTICE 3
1. Select MSV column, then open Conditional Formatting -> New Rule
Select Use a formula to determine which cells to format, then input this
formula:
=NOT(ISNA(MATCH(A5,Transfers!$C$2:$C$16,0)))
Set the format you want, then click OK.
2. First, create new sheet with 3 columns: MSV, H v tn, Ngy sinh.
In MSV column, fill the student IDs from both NHAE408.2 sheet and Transfers
sheet.
Then use VLOOKUP function to automatically retrieve full name and DOB of
students from NHAE408.2 sheet and NHAE408.1 sheet.
Set format of Ngy sinh column: dd/mm/yyyy
See Practice 5 to know how to extract first name from full name. Then sort
the first name column A to Z.

PRACTICE 4
A. Statistical
3. Use LN function.
4. Open Data Analysis -> Descriptive Statistics.
- Input range: $B$1:$B$152
- Labels in first row
- Summary statistics
Then click OK.
5. Open Data Analysis -> Histogram.
- Input range: $B$1:$B$152
- Bin range: $H$1:$H$45
- Labels
- Chart output
Then click OK.
6. Select Beta column, open Insert -> Pivot Chart, then click OK
- Rows: Beta
- Values: Count of Beta
You can select data in Row Labels, then use PivotTable Tools -> Analyze ->
Group Selection to group the row labels.
7. Use CORREL function.
8. Use SLOPE function.
9. Copy Ret(), Ret() and Ret() columns to a new sheet, then open Data
Analysis -> Anova: Single factor:
- Input range: $A$1:$C$152
- Labels in first row
Then click OK. Here we have P-value > 0.05, so we cannot reject the null
hypothesis: Alpha, Beta and Delta have similar returns.
10. Copy Ret() and Ret() columns to a new sheet, then open Data Analysis
-> F-test Two-Sample for Variances:

- Variable 1 range: $A$1:$A$152


- Variable 2 range: $B$1:$B$152
- Labels
Then click OK. Here we have P-value < 0.05, so we can reject the null
hypothesis: Alpha and Beta returns have the same variance.
Then we open Data Analysis -> T-test Two-Sample Assuming Unequal
Variances
Input the same values as above, then click OK. Here we have P-value > 0.05,
so we cannot reject the null hypothesis: Alpha and Beta have similar returns.
B. Financial functions
1. Use PV function.
2. Use PMT function.
3. Use NPV function.
4. Use DURATION and MDURATION function.
5. Use IRR function.
6. Just divide payment to rate.
7. Calculate PV of cash flows, then sum them.
C. Charts
1. Select Date and Delta columns, then choose Insert -> Line chart -> Line.
2. Select Date, Alpha, Beta and Delta columns, then choose Insert -> Line
chart -> Line.
3. Select Date, Alpha and Ret() columns, choose Insert -> Line chart ->
Line. Then right click the Ret() line graph, choose Format Data Series, set
Plot Series on = Secondary Axis.
4. Use random functions (e.g: RANDBETWEEN) to create the price table. Then
make the line chart from that table.
6. Use AVERAGE, STDEV.S and CORREL functions to calculate means,
standard deviations and correlation coefficient of Ret() and Ret().
Make the Efficient Frontier table with the following columns: wAlpha (weight
of Alpha), wBeta (weight of Beta), StddevP (standard deviation of the
portfolio), meanP (expected return of the portfolio).

Select StddevP and meanP columns, then choose Insert -> Scatter (X, Y) or
Bubble Chart -> Scatter with Smooth Lines.
D. Pivot
Select the table, open Insert -> PivotTable, then click OK.
1. Rows: Lp

Values: Count of Lp

2. Filters: Lp = A3, Nm hc = 2

Values: Count of Lp

3. Filters: Nm hc = 2

Values: Average of Cng ngh

4. Rows: Lp
Values: Max of Cng ngh, Min of Cng ngh, Max of Ti chnh, Min of Ti
chnh, Max of Ngn hng, Min of Ngn hng
5. Rows: Nm hc
Values: Average of Cng ngh, Average of Ti chnh, Average of Ngn hng
6. Select the PivotTable of Question 5, then open PivotTable Tools -> Analyze
-> PivotChart. Select the type of chart you want, then click OK.

PRACTICE 5
A. Solver
1. Set a random rate in C7, calculate PV of cash flows in C5:M5, then
calculate NPV in C6.
Open Data -> What-If Analysis -> Goal Seek:
- Set cell: $C$6
- To value: 0
- By changing cell: $C$7
Then click OK.
2. Set a random rate in C14, calculate PV of cash flows in C12:J12, then
calculate NPV in C13.
Open Data -> Solver:
- Set objective: $C$13
- To: Value of 0
- By changing variable cells: $C$9
Then click Solve.
3. Set annual production of Theta in D26:F26, annual production of Tau in
D27:F27, annual production of both products in D28:F28, annual cost and
total cost in D29:G29, and annual profit and total profit in D30:G30.
Open Data -> Solver:
- Set objective: $G$30
- To: Max
- By changing variable cells: $D$26:$F$27
- Subject to the Constraints: $D$28:$F$28 <= 100

$G$29 <= 2000

Then click Solve.


B. Text
1. Set formula of column
",TEXT(D2,"d/m/yyyy"))

E:

Set formula of column F: =TRIM(E2)


The result is column F.

=CONCATENATE(A2,"

",B2,"

",C2,"

2+3. Set column G to contain the total number of spaces:


=LEN(F2)-LEN(SUBSTITUTE(F2," ",""))
Set column H to contain the position of the first space:
=FIND(" ",F2)
Set column I to contain the position of the space prior to the last space:
=FIND("$",SUBSTITUTE(F2," ","$",G2-1))
Set column J to contain the position of the last space:
=FIND("$",SUBSTITUTE(F2," ","$",G2))
Set column K to contain the extracted last name:
=LEFT(F2,H2-1)
Set column L to contain the extracted middle name:
=IF(I2-H2-1>0,MID(F2,H2+1,I2-H2-1),"")
Set column M to contain the extracted first name:
=MID(F2,I2+1,J2-I2-1)
Set column N to contain the extracted DOB:
=RIGHT(F2,LEN(F2)-J2)
C. Reference
1. Use VLOOKUP function.
2. Use MATCH function.
3. See the result of the previous question.
D. Table
1. Select any cell of the table, choose Insert -> Table, then click OK.
2. Select table, then choose Insert -> Slicer. Tick the columns you want to
create slicer, then click OK.
3. Select table, choose Table Tools -> Convert to Range, then click OK.

Das könnte Ihnen auch gefallen