XP
Introduction to MS Excel
XP
Contents
1. Identify excel components
2. Descriptions of Excel
components
3. Excel’s arithmetic operators
4. Know the order of precedence
5. Cell Referencing
6. Work with the Insert Function
button
7. Math and Statistical functions
8. Define functions, and functions
within functions
9. Examine the Insert Function
dialog box
10.Create column and pie charts in
Excel
11. Create a chart using the Chart
Wizard
12. Use of If
13. Count Function
14. Function Auditing
15. Sorting
16. Shortcut Keys
17. Add data and record a basic
script
18. create
XP
1. Identify Excel components
3
XP
2. Descriptions of Excel components
4
XP
3. Excel’s arithmetic operators
Arithmetic operations, symbols and description of their use.
5
XP
4. Know the order of precedence
The order of precedence rules must be considered when creating
expressionsmomo. The chart below illustrates Excel’s order of
precedence and shows sample expressions and the result of each
expression.
6
XP
5. Cell Referencing
7
XP
5. Cell Referencing
8
XP
5. Cell Referencing
9
XP
6. Work with the Insert Function
button
• Excel supplies more than 350 functions organized
into 10 categories:
– Database, Date and Time, Engineering, Financial,
Information, Logical, Lookup, Math, Text and Data,
and Statistical functions
• You can use the Insert Function button on the
Formula bar to select from a list of functions.
• A series of dialog boxes will assist you in filling in
the arguments of the function and this process also
enforces the use of proper syntax.
10
XP
7. Math and Statistical functions
This chart shows some commonly used math and
statistical functions and a description of what they do.
11
XP
8. Define functions, and
functions within functions
• The SUM function is a very commonly used math function
in Excel.
• A basic formula example to add up a small number of cells
is =A1+A2+A3+A4, but that method would be
cumbersome if there were 100 cells to add up.
• Use Excel's SUM function to total the values in a range of
cells like this: SUM(A1:A100).
• You can also use functions within functions. Consider the
expression =ROUND(AVERAGE(A1:A100),1).
– This expression would first compute the average of all the values
from cell A1 through A100 and then round that result to 1 digit to
the right of the decimal point
12
XP
9. Examine the Insert Function
dialog box
This dialog box appears when you click the Insert Function
button. It can assist you in defining your function.
13
XP
10. Create column and pie
charts in Excel
• Charts, or graphs, provide visual representations of the
workbook data.
• A chart may be embedded in an existing worksheet, or can
be created on a separate chart sheet, with its own tab in the
workbook.
• You can use Excel’s Chart Wizard to quickly and easily
create charts.
• The Chart Wizard is a series of dialog boxes that prompt
you for information about the chart you want to generate
14
XP
11. Create a chart using
the Chart Wizard
• To create a chart with the Chart Wizard:
– Select the data you want to chart, which will be your data source
– Click the Chart Wizard button on the standard toolbar
– In the first step of the chart wizard, select the chart type and sub-
type
– In the second step of the Chart Wizard, make any additions or
modifications to the chart's data source
– In the third step, make any modifications to the chart's appearance
– In the fourth and final step, specify the location for the chart, then
click the OK button
15
XP
11 Contd. Chart Wizard dialog box 1
Choose a chart type and view examples of that type in dialog box 1.
Choose which type of chart
you want in this pane.
Select a sub-type of
that chart in this pane.
Click and hold this
button down to see a
preview of your chart.
16
XP
11 Contd. Choosing a data series
• You can alter the data source during step 2 of the Chart
Wizard and also choose whether to organize the data
source by rows or by columns.
• The data source is organized into a collection of data
series.
– A data series consists of data values, which are plotted on the
chart's vertical, or Y-axis
– The data series’ category values, or X values, are on the horizontal
axis, called the X-axis
• A chart can have several data series all plotted against a
common set of category values.
17
XP
11. Contd. Chart Wizard dialog box 2
During the second step of the
Chart Wizard, you specify
the data to be displayed
in the chart, which is also
known as the chart's data
source.
Specify the cell range and
whether the data series is in
rows or columns.
18
XP
11. Contd. Chart Wizard dialog box 2
During the second step of the
Chart Wizard, you specify
the data to be displayed
in the chart, which is also
known as the chart's data
source.
Specify the cell range and
whether the data series is in
rows or columns.
19
XP
11. Contd. Chart Wizard dialog box 2
During the second step of the
Chart Wizard, you specify
the data to be displayed
in the chart, which is also
known as the chart's data
source.
Specify the cell range and
whether the data series is in
rows or columns.
20
XP
11. Contd. Chart Wizard dialog box 2
During the second step of the
Chart Wizard, you specify
the data to be displayed
in the chart, which is also
known as the chart's data
source.
Specify the cell range and
whether the data series is in
rows or columns.
21
XP
• To allow for three or more outcomes
• One IF function is placed inside another IF
function to test an additional condition
• More than one IF function can be nested
12. Creating Nested IFs
22
XP
12 Contd. Creating Nested IFs
23
XP
Summarizing Data Conditionally
• Use COUNTIF, SUMIF, and AVERAGEIF
functions to calculate a conditional count, sum, or
average using only cells that meet a particular
condition
12 Contd. Use of Different If
Function
24
XP
Using the COUNTIF Function
• Calculates the number of cells in a range that match
specified criteria
• Sometimes referred to as a conditional count
• Syntax:
12 Contd. Use of Different If
Function
25
XP
Using the SUMIF Function
• Adds values in a range that meet your criteria
• Also called a conditional sum
• Syntax:
12 Contd. Use of Different If
Function
26
XP
12 Contd. Use of Different If
Function
27
XP
13 Count Function
28
XP
14. Function Auditing
29
XP
15. Sorting
30
XP
16. Shortcut keys
31
XP
17. Add data and record a basic script
• Create a new Excel workbook.
• Copy the following fruit sales data and paste it into the worksheet,
starting at cell A1.
• Open the Automate tab. If you don't see the Automate tab, check the
ribbon overflow by selecting the drop-down arrow.
• Select the Record Actions button.
• Select cells A2:C2 (the "Oranges" row) and set the fill color to orange.
• Stop the recording by selecting the Stop button. 32
XP
18. Contd. Edit an existing script
The previous script colored the "Oranges" row to be orange. Let's add a yellow
row for the "Lemons".
1. From the now-open Details pane, select the Edit button.
2. You should see something similar to this code:
This code gets the current worksheet from the workbook. Then, it sets
the fill color of the range A2:C2.
33
XP
18. Contd. Edit an existing script
3. Add the following line to the end of the script (between where the color is
set and the closing }):
selectedSheet.getRange("A3:C3").getFormat().getFill().setColor("yellow
");
4. Test the script by selecting Run. Your workbook should now look like this:
34
XP
18. Contd. Create a Table
Let's convert this fruit sales data into a table. We'll use our
script for the entire process.
1. Add the following line to the end of the script (before the
closing }):
let table = selectedSheet.addTable("A1:C5", true);
1. That call returns a Table object. Let's use that table to sort the
data. We'll sort the data in ascending order based on the values in
the "Fruit" column. Add the following line after the table
creation:
table.getSort().apply([{ key: 0, ascending: true }]); 35
XP
18. Contd. Create a Table
Your script should look like this:
function main(workbook: ExcelScript.Workbook) {
// Set fill color to FFC000 for range Sheet1!A2:C2
let selectedSheet = workbook.getActiveWorksheet();
selectedSheet.getRange("A2:C2").getFormat().getFill().setColor("FFC000");
selectedSheet.getRange("A3:C3").getFormat().getFill().setColor("yellow");
let table = selectedSheet.addTable("A1:C5", true);
table.getSort().apply([{ key: 0, ascending: true }]);
}
3. Run the script. You should see a table like this:
36
XP
18. Contd. Re-run the script
1. Create a new worksheet in the current workbook.
2. Copy the fruit data from the beginning of the tutorial and paste
it into the new worksheet, starting at cell A1.
3. Run the script.
37
XP
18. References
• https://www.slideshare.net/love1200/ms-excel-
ppt-presentation
• https://www.youtube.com/watch?v=PfOo2MjiSX
0
• https://www.youtube.com/watch?v=-
ujVQzTtxSg&list=PLWPirh4EWFpEpO6NjjWLb
KSCb-wx3hMql
• https://learn.microsoft.com/en-
us/office/dev/scripts/tutorials/excel-tutorial
38

MS_Excel_Module4.1 ffor beginners yo .pptx

  • 1.
  • 2.
    XP Contents 1. Identify excelcomponents 2. Descriptions of Excel components 3. Excel’s arithmetic operators 4. Know the order of precedence 5. Cell Referencing 6. Work with the Insert Function button 7. Math and Statistical functions 8. Define functions, and functions within functions 9. Examine the Insert Function dialog box 10.Create column and pie charts in Excel 11. Create a chart using the Chart Wizard 12. Use of If 13. Count Function 14. Function Auditing 15. Sorting 16. Shortcut Keys 17. Add data and record a basic script 18. create
  • 3.
  • 4.
    XP 2. Descriptions ofExcel components 4
  • 5.
    XP 3. Excel’s arithmeticoperators Arithmetic operations, symbols and description of their use. 5
  • 6.
    XP 4. Know theorder of precedence The order of precedence rules must be considered when creating expressionsmomo. The chart below illustrates Excel’s order of precedence and shows sample expressions and the result of each expression. 6
  • 7.
  • 8.
  • 9.
  • 10.
    XP 6. Work withthe Insert Function button • Excel supplies more than 350 functions organized into 10 categories: – Database, Date and Time, Engineering, Financial, Information, Logical, Lookup, Math, Text and Data, and Statistical functions • You can use the Insert Function button on the Formula bar to select from a list of functions. • A series of dialog boxes will assist you in filling in the arguments of the function and this process also enforces the use of proper syntax. 10
  • 11.
    XP 7. Math andStatistical functions This chart shows some commonly used math and statistical functions and a description of what they do. 11
  • 12.
    XP 8. Define functions,and functions within functions • The SUM function is a very commonly used math function in Excel. • A basic formula example to add up a small number of cells is =A1+A2+A3+A4, but that method would be cumbersome if there were 100 cells to add up. • Use Excel's SUM function to total the values in a range of cells like this: SUM(A1:A100). • You can also use functions within functions. Consider the expression =ROUND(AVERAGE(A1:A100),1). – This expression would first compute the average of all the values from cell A1 through A100 and then round that result to 1 digit to the right of the decimal point 12
  • 13.
    XP 9. Examine theInsert Function dialog box This dialog box appears when you click the Insert Function button. It can assist you in defining your function. 13
  • 14.
    XP 10. Create columnand pie charts in Excel • Charts, or graphs, provide visual representations of the workbook data. • A chart may be embedded in an existing worksheet, or can be created on a separate chart sheet, with its own tab in the workbook. • You can use Excel’s Chart Wizard to quickly and easily create charts. • The Chart Wizard is a series of dialog boxes that prompt you for information about the chart you want to generate 14
  • 15.
    XP 11. Create achart using the Chart Wizard • To create a chart with the Chart Wizard: – Select the data you want to chart, which will be your data source – Click the Chart Wizard button on the standard toolbar – In the first step of the chart wizard, select the chart type and sub- type – In the second step of the Chart Wizard, make any additions or modifications to the chart's data source – In the third step, make any modifications to the chart's appearance – In the fourth and final step, specify the location for the chart, then click the OK button 15
  • 16.
    XP 11 Contd. ChartWizard dialog box 1 Choose a chart type and view examples of that type in dialog box 1. Choose which type of chart you want in this pane. Select a sub-type of that chart in this pane. Click and hold this button down to see a preview of your chart. 16
  • 17.
    XP 11 Contd. Choosinga data series • You can alter the data source during step 2 of the Chart Wizard and also choose whether to organize the data source by rows or by columns. • The data source is organized into a collection of data series. – A data series consists of data values, which are plotted on the chart's vertical, or Y-axis – The data series’ category values, or X values, are on the horizontal axis, called the X-axis • A chart can have several data series all plotted against a common set of category values. 17
  • 18.
    XP 11. Contd. ChartWizard dialog box 2 During the second step of the Chart Wizard, you specify the data to be displayed in the chart, which is also known as the chart's data source. Specify the cell range and whether the data series is in rows or columns. 18
  • 19.
    XP 11. Contd. ChartWizard dialog box 2 During the second step of the Chart Wizard, you specify the data to be displayed in the chart, which is also known as the chart's data source. Specify the cell range and whether the data series is in rows or columns. 19
  • 20.
    XP 11. Contd. ChartWizard dialog box 2 During the second step of the Chart Wizard, you specify the data to be displayed in the chart, which is also known as the chart's data source. Specify the cell range and whether the data series is in rows or columns. 20
  • 21.
    XP 11. Contd. ChartWizard dialog box 2 During the second step of the Chart Wizard, you specify the data to be displayed in the chart, which is also known as the chart's data source. Specify the cell range and whether the data series is in rows or columns. 21
  • 22.
    XP • To allowfor three or more outcomes • One IF function is placed inside another IF function to test an additional condition • More than one IF function can be nested 12. Creating Nested IFs 22
  • 23.
    XP 12 Contd. CreatingNested IFs 23
  • 24.
    XP Summarizing Data Conditionally •Use COUNTIF, SUMIF, and AVERAGEIF functions to calculate a conditional count, sum, or average using only cells that meet a particular condition 12 Contd. Use of Different If Function 24
  • 25.
    XP Using the COUNTIFFunction • Calculates the number of cells in a range that match specified criteria • Sometimes referred to as a conditional count • Syntax: 12 Contd. Use of Different If Function 25
  • 26.
    XP Using the SUMIFFunction • Adds values in a range that meet your criteria • Also called a conditional sum • Syntax: 12 Contd. Use of Different If Function 26
  • 27.
    XP 12 Contd. Useof Different If Function 27
  • 28.
  • 29.
  • 30.
  • 31.
  • 32.
    XP 17. Add dataand record a basic script • Create a new Excel workbook. • Copy the following fruit sales data and paste it into the worksheet, starting at cell A1. • Open the Automate tab. If you don't see the Automate tab, check the ribbon overflow by selecting the drop-down arrow. • Select the Record Actions button. • Select cells A2:C2 (the "Oranges" row) and set the fill color to orange. • Stop the recording by selecting the Stop button. 32
  • 33.
    XP 18. Contd. Editan existing script The previous script colored the "Oranges" row to be orange. Let's add a yellow row for the "Lemons". 1. From the now-open Details pane, select the Edit button. 2. You should see something similar to this code: This code gets the current worksheet from the workbook. Then, it sets the fill color of the range A2:C2. 33
  • 34.
    XP 18. Contd. Editan existing script 3. Add the following line to the end of the script (between where the color is set and the closing }): selectedSheet.getRange("A3:C3").getFormat().getFill().setColor("yellow "); 4. Test the script by selecting Run. Your workbook should now look like this: 34
  • 35.
    XP 18. Contd. Createa Table Let's convert this fruit sales data into a table. We'll use our script for the entire process. 1. Add the following line to the end of the script (before the closing }): let table = selectedSheet.addTable("A1:C5", true); 1. That call returns a Table object. Let's use that table to sort the data. We'll sort the data in ascending order based on the values in the "Fruit" column. Add the following line after the table creation: table.getSort().apply([{ key: 0, ascending: true }]); 35
  • 36.
    XP 18. Contd. Createa Table Your script should look like this: function main(workbook: ExcelScript.Workbook) { // Set fill color to FFC000 for range Sheet1!A2:C2 let selectedSheet = workbook.getActiveWorksheet(); selectedSheet.getRange("A2:C2").getFormat().getFill().setColor("FFC000"); selectedSheet.getRange("A3:C3").getFormat().getFill().setColor("yellow"); let table = selectedSheet.addTable("A1:C5", true); table.getSort().apply([{ key: 0, ascending: true }]); } 3. Run the script. You should see a table like this: 36
  • 37.
    XP 18. Contd. Re-runthe script 1. Create a new worksheet in the current workbook. 2. Copy the fruit data from the beginning of the tutorial and paste it into the new worksheet, starting at cell A1. 3. Run the script. 37
  • 38.
    XP 18. References • https://www.slideshare.net/love1200/ms-excel- ppt-presentation •https://www.youtube.com/watch?v=PfOo2MjiSX 0 • https://www.youtube.com/watch?v=- ujVQzTtxSg&list=PLWPirh4EWFpEpO6NjjWLb KSCb-wx3hMql • https://learn.microsoft.com/en- us/office/dev/scripts/tutorials/excel-tutorial 38