<HTML
><HEAD
><TITLE
>MATCH</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.54"><LINK
REL="HOME"
TITLE="Gnumeric's user manual"
HREF="gnumeric.html"><LINK
REL="UP"
TITLE="Reference"
HREF="function-reference.html#AEN1187"><LINK
REL="PREVIOUS"
TITLE="TANH"
HREF="r8432.html"><LINK
REL="NEXT"
TITLE="SUBSTITUTE"
HREF="r8488.html"></HEAD
><BODY
CLASS="REFENTRY"
><DIV
CLASS="NAVHEADER"
><TABLE
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TH
COLSPAN="3"
ALIGN="center"
>Gnumeric's user manual</TH
></TR
><TR
><TD
WIDTH="10%"
ALIGN="left"
VALIGN="bottom"
><A
HREF="r8432.html"
>Prev</A
></TD
><TD
WIDTH="80%"
ALIGN="center"
VALIGN="bottom"
></TD
><TD
WIDTH="10%"
ALIGN="right"
VALIGN="bottom"
><A
HREF="r8488.html"
>Next</A
></TD
></TR
></TABLE
><HR
ALIGN="LEFT"
WIDTH="100%"></DIV
><H1
><A
NAME="AEN8460"
><A
NAME="GNUMERIC-MATCH"
></A
>MATCH</A
></H1
><DIV
CLASS="REFNAMEDIV"
><A
NAME="AEN8465"
></A
><H2
>Name</H2
>MATCH&nbsp;--&nbsp;</DIV
><DIV
CLASS="REFSYNOPSISDIV"
><A
NAME="AEN8468"
></A
><H2
>Synopsis</H2
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><PRE
CLASS="SYNOPSIS"
>MATCH(seek,vector[,type])</PRE
></TD
></TR
></TABLE
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN8470"
></A
><H2
>Description</H2
><P
>The MATCH function finds the row index of @seek in @vector and returns it. If the area is longer than it is wide then the sense of the search is rotated. Alternatively a single array can be used.</P
><P
>The @type parameter, which defaults to +1, controls the search:</P
><P
>If @type = 1,  finds largest value &#60;= @seek.</P
><P
>If @type = 0,  finds first value == @seek.</P
><P
>If @type = -1, finds smallest value &#62;= @seek.</P
><P
></P
><P
>For type 0, the data can be in any order.  For types -1 and +1, the data must be sorted.  (And in this case, MATCH uses a binary search to locate the index.)</P
><P
>If @seek could not be found, #N/A is returned.</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN8480"
></A
><H2
>Examples</H2
><P
></P
><P
></P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN8484"
></A
><H2
>See also</H2
><P
>        <A
HREF="r4946.html#GNUMERIC-LOOKUP"
>LOOKUP</A
>
      </P
></DIV
><DIV
CLASS="NAVFOOTER"
><HR
ALIGN="LEFT"
WIDTH="100%"><TABLE
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><A
HREF="r8432.html"
>Prev</A
></TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="gnumeric.html"
>Home</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
HREF="r8488.html"
>Next</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><A
NAME="GNUMERIC-TANH"
></A
>TANH</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="function-reference.html#AEN1187"
>Up</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
NAME="GNUMERIC-SUBSTITUTE"
></A
>SUBSTITUTE</TD
></TR
></TABLE
></DIV
></BODY
></HTML
>