<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><!-- InstanceBegin template="/Templates/book_pages_template.dwt" codeOutsideHTMLIsLocked="false" -->
<head>
<!-- InstanceBeginEditable name="doctitle" -->
<title>Microsoft Excel Tips / Excel Tutorial / Excel Spreadsheet Help / Excel Tip .com</title>

<!-- InstanceEndEditable --> 
<style><!--
.MsoBodyText
	{text-align:justify;
	line-height:14.0pt;
	font-size:10.0pt;
	font-family:Arial;
	letter-spacing:.25pt;}
.MsoBodyTextIndent
	{text-align:justify;
	line-height:14.0pt;
	font-size:10.0pt;
	font-family:Arial;
	letter-spacing:.25pt;
	font-weight:bold;}
.MsoBodyText2
	{text-align:justify;
	line-height:14.0pt;
	font-size:10.0pt;
	font-family:Arial;
	letter-spacing:.25pt;}
.listnumber
	{text-align:justify;
	line-height:14.0pt;
	font-size:10.0pt;
	font-family:Arial;
	letter-spacing:.25pt;}
.problemsolution
	{line-height:14.0pt;
	font-size:12.0pt;
	font-family:Arial;
	color:#636363;
	letter-spacing:.25pt;
	text-shadow:auto;
	font-weight:bold;}
.Chapter
	{text-align:center;
	font-size:20.0pt;
	font-family:Arial;
	letter-spacing:.25pt;
	text-shadow:auto;
	font-weight:bold;}
.HeaderEven
	{line-height:14.0pt;
	tab-stops:center 207.65pt right 415.3pt;
	font-size:10.0pt;
	font-family:Arial;
	letter-spacing:.25pt;}
.HeaderOdd
	{text-align:justify;
	line-height:14.0pt;
	tab-stops:center 207.65pt right 415.3pt;
	font-size:10.0pt;
	font-family:Arial;
	letter-spacing:.25pt;}
.Section1
	{page:Section1;}
.Section2
	{page:Section2;}
-->
</style>
<!-- \/--OPTIMIZATION BY: IRUBIN CONSULTING --------------------------------------------------\/ -->
<meta name="description" content="">
<meta name="keywords" content="">

<meta name="robots" content="all">
<meta name="revisit-after" content="15 days">
<meta http-equiv="PICS-Label" content='(PICS-1.1 "http://www.weburbia.com/safe/ratings.htm" l r (s 0))'>
<meta name="Classification" content="Microsoft Excel, Excel Spreadsheet, Excel Tips and Tricks, Microsoft Office">
<meta name="Copyright" content="2002 copyright">
<meta name="MSSmartTagsPreventParsing" content="TRUE">
<!-- /\------------------------------------------------------------/\ -->
<link rel="stylesheet" href="/css/main.css" type="text/css">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<!-- InstanceBeginEditable name="head" --><!-- InstanceEndEditable -->
</head>

<body bgcolor="#F79300" text="#333333" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">

<!--#include virtual="/cgi-bin/engine.pl?action=header"-->

<table width="100%" border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
  <tr>
    <td width="100%" valign="top" class="mtdleft">
	    <table border="0" cellspacing="0" cellpadding="0" align="right">
  <tr>
    <td >
              		  <object width="120" height="600">
              <param name="movie" value="/swf/exceltipflash_vertical.swf">
              <param name="quality" value="high">
              <embed src="/swf/exceltipflash_vertical.swf" quality="high" width="120" height="600"></embed>
			  </object> 
            </td>
  </tr>
</table>

	  <!-- InstanceBeginEditable name="Main Content Area" -->
	<p align="center"><font class="chaptertitle">Chapter 7 continued ...</font><br>
        </p>
	<p >Perform the operation again to copy the formula (without the = sign)
  from Cell E1 to Cell F1, and paste over the reference E1. The result is a single
  formula: =SUM(SUM(A:A)+SUM(B:B)).</p>
<p class=head-2 ><a
name="_Toc25863140"></a><a name="_Toc26773927">Adding Statistical Formulas</a></p>
<p class=head-3 ><a
name="_Toc25863141"></a><a name="_Toc26773928">Analysis ToolPak, Analysis ToolPak-VBA</a></p>
<p >You should also install the Analysis ToolPak-VBA add-in. This add-in
  includes VBA functions that are useful in developing applications in the VBA
  programming language.</p>
<p class=HeaderEven  style='text-align:justify;'>Install both add-ins before
  beginning to work in Excel.</p>
<h6  style='text-align:justify'>Installing the add-ins</h6>
<p class=listnumber > 1.<span
style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>
  From the <b>Tools </b>menu, select <b>Add-ins</b>.</p>
<p class=listnumber > 2.<span
style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>
  Select both add-ins, Analysis ToolPak and Analysis ToolPak-VBA.</p>
<p class=listnumber > 3.<span
style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>
  Click <b>OK</b>.</p>
<p >Now check to see if the functions included in Analysis ToolPak have
  been installed. Press <b>Shift+F3</b> (<b>Paste Function</b>) and select <b>All</b>.
  In <b>Select Function</b>, notice the functions whose names are printed in lower-case
  letters. You have installed these functions by installing the Analysis ToolPak.</p>
<p class=head-2 ><a name="_Toc25863142"></a><a name="_Toc26773929">Array
  Formula</a></p>
<p align=left  style='text-align:left'> <img width=204 height=204
src="images/image017.gif" align=left hspace=12 v:shapes="_x0000_s1383">
  Use an <b>array formula</b> to create a formula that performs complex calculations.
</p>
<p align=left  style='text-align:left'><b>For example:</b> there are names
  defined for three ranges:</p>
<p align=left  style='text-align:left;'>Range A4:A12        Part_Number</p>
<p align=left  style='text-align:left;'><span
lang=FR>Range B4:B12        Quantity</span></p>
<p align=left  style='text-align:left;'>Range C4:C12        Price</p>
<p align=left  style='text-align:left'>In Cell D16 is the <b>array formula
  </b>={(SUM(Quantity*Price)}.</p>
<p align=left  style='text-align:left'>The formula returns the result of
  the Quantity range times the Price range.</p>
<h1 ><span style='font-size:10.0pt;
font-weight:normal'>                                           </span></h1>
<div align=left >
  <table border=0 cellspacing=0 cellpadding=0 width=456>
    <tr>
      <td width=60 valign=top class="Normal"> <p > <img width=28 height=45
  src="images/image018.jpg" v:shapes="_x0000_i1031"> </p></td>
      <td width=396 valign=top class="Normal"> <h1 ><a name="_Toc25998314">Tip
          – To enter an array formula, you must hold down Ctrl+Shift while hitting
          enter.</a></h1></td>
    </tr>
  </table>
</div>
<p >Cell D19 contains the formula ={SUM(IF(Part_Number=C19,Price*Quantity,0)}.</p>
<p class=listnumber  style='line-height:12.0pt;'>The formula returns the
  result of the Quantity times the Price for part number A663.</p>
<p >Use the following technique to enter an <b>array formula</b>:</p>
<p class=listnumber > 1.<span
style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>
  In any cell, enter the formula =SUM(Price*Quantity). Define Names before beginning
  to enter the formula.</p>
<p class=listnumber > 2.<span
style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>
  Press these three keys simultaneously: <b>Ctrl+Shift+Enter</b>.</p>
<p class=listnumber > 3.<span
style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>
  The <b>array formula</b> is created when these three keys are pressed simultaneously.
  In order to identify the <b>array formula</b>, brackets ({}) are inserted around
  the formula. </p>
<p class=listnumber > 4.<span
style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>
  If you forget to hold down <b>Ctrl+Shift</b> while pressing <b>Enter</b>, the
  formula will evaluate to the <b>VALUE! ERROR</b>.  If this happens, then press
  <b>F2</b> (Edit Cell), or use the mouse to select any character in the formula
  bar. </p>
<p class=head-3 ><a name="_Toc25863143"></a><a name="_Toc26773930">The
  technical side of array formulas</a></p>
<p >An <b>array </b>saves calculations in the temporary memory, which are
  used later in the calculation of the total. The ability to save results in the
  temporary memory allows you to perform complex calculations such as the one
  displayed.</p>
<p class=head-3 ><a name="_Toc25863144"></a><a name="_Toc26773931">Using
  array formulas to create links with a change of direction</a></p>
<p > <img width=204 height=131
src="images/image020.jpg" align=left hspace=12 v:shapes="_x0000_s1356">
  Select a range of cells in the sheet, and press <b>Ctrl+C</b>. Select the last
  cell in the sheet, right-click, and select <b>Paste Special</b>.</p>
<p >In the <b>Paste Special</b> dialog box, there is a <b>Paste link</b>
  option. This option allows you to paste link formulas into cells. The <b>Paste
  Special</b> dialog box also has a <b>Transpose</b> option, which pastes the
  data in the opposite direction (that is, horizontally to vertically, or vice
  versa). </p>
<br clear=all style='page-break-before:
always'>
<p class=problemsolution ><span style='text-shadow:none'>Problem</span></p>
<p >You cannot select the <b>Transpose</b> option together with the <b>Paste
  link </b>option. In other words, you cannot create a link while changing the
  direction of the paste operation.</p>
<p class=problemsolution ><span style='text-shadow:none'>Solution</span></p>
<p >Use the TRANSPOSE function together with the <b>array formula</b> technique
  to create links that change direction.</p>
<p >First, measure the number of cells in the selected columns and rows.
  When selecting the range, notice the <b>Name box</b>.</p>
<p >Select range A2:B6, which has the name <b>Range</b> defined for it.
  The size of the range is 4Rx2C – that is, four columns by two rows.</p>
<p >Starting with Cell A8, select a range whose size is 2Rx4C – that is,
  the same size in the opposite direction. </p>
<p class=listnumber > 1.<span
style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>
  Enter the formula =TRANSPOSE, and press <b>Ctrl+A</b>.</p>
<p class=listnumber > 2.<span
style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>
  Press <b>F3</b>, paste the name <b>RANGE</b>, and press <b>Ctrl+Shift+Enter</b>.</p>
    <p >&nbsp;</p>
      <p align="center"><a href="/excel_book/chapter7/p2.html">PREVIOUS</a> &nbsp;<a href="/excel_book/chapter7/p1.html">1</a>
        <a href="/excel_book/chapter7/p2.html">2</a> <a href="/excel_book/chapter7/p3.html">3</a>
        <a href="/excel_book/chapter7/p4.html">4</a> <a href="/excel_book/chapter7/p5.html">5</a>
        <a href="/excel_book/chapter7/p6.html">6</a> <a href="/excel_book/chapter7/p7.html">7</a>
        <a href="/excel_book/chapter7/p8.html">8</a> <a href="/excel_book/chapter7/p9.html">9</a>
        &nbsp;&nbsp;<a href="/excel_book/chapter7/p4.html">NEXT</a></p>
<!-- InstanceEndEditable --> 
    </td>
	      
    <td valign="top" class="mtdright">
	
	<!--#include virtual="/cgi-bin/engine.pl?action=right_side"-->


	 </td>
  </tr>
</table>
<!--#include virtual="/cgi-bin/engine.pl?action=footer"-->


</body>
<!-- InstanceEnd --></html>
