\HeaderA{fbinary-methods}{Binary measures for pairwise peak-list comparison}{fbinary.Rdash.methods}
\aliasA{fbinary,list,NULL-method}{fbinary-methods}{fbinary,list,NULL.Rdash.method}
\aliasA{fbinary,Massvector,Massvector-method}{fbinary-methods}{fbinary,Massvector,Massvector.Rdash.method}
\aliasA{fbinary,Massvectorlist,Massvector-method}{fbinary-methods}{fbinary,Massvectorlist,Massvector.Rdash.method}
\aliasA{fbinary,Massvectorlist,NULL-method}{fbinary-methods}{fbinary,Massvectorlist,NULL.Rdash.method}
\aliasA{fbinary,numeric,numeric-method}{fbinary-methods}{fbinary,numeric,numeric.Rdash.method}
\keyword{methods}{fbinary-methods}
\begin{Description}\relax
Binary measures are comptued on entries of a
contingency table.\\
Implements the:\\
\Itemize{
\item Relative Mutual information,\\
\item Fowlkes Mallows statistics \eqn{M_11/sqrt(M_1Y*M_1X)}{},\\
\item Gower coefficient
\eqn{(M_01^XY+M_10^XY)/(M_01^XY+M_10^XY+M_11^XY)}{},\\
\item Huberts \eqn{\Gamma}{}
}
\end{Description}
\begin{Arguments}
\begin{ldescription}
\item[\code{obx}] see below in \bold{Methods} section
\item[\code{oby}] see above in \bold{Methods} section
\item[\code{error}] measurement error
\item[\code{ppm}] if \code{TRUE} then error in parts per million(ppm), in
arbitrary units otherwise.
\item[\code{weight}] should mass accuracy be weighted
\item[\code{uniq}] if \code{TRUE} compute non-crossing matching.
\item[\code{method}] type of dissimilarity:
\Itemize{
\item rmi -- relative mutual information
\item fm -- fowlkes mallows statistics
\item hg -- huberts gamma
\item gower -- gower coefficient
}

\item[\code{N}] default 0 - total length of alinged peak-lists.
\item[\code{range}] experimental
\end{ldescription}
\end{Arguments}
\begin{Section}{Methods}
\describe{
\item[obx = "numeric", oby = "numeric"] expects two numeric vectors as
parameters, returns scalar
\item[obx = "Massvector", oby = "Massvector"] returns scalar (\code{numeric})
\item[obx = "Massvectorlist", oby = "Massvector"] returns a vector with
all pairwise dissimilaritities.
\item[obx = "Massvectorlist", oby = "NULL"] returns object of class \code{\LinkA{dist}{dist}}
\item[obx = "list", oby = "NULL"] returns object of class \code{\LinkA{dist}{dist}}
}
\end{Section}
\begin{Author}\relax
Witold E. Wolski \email{witek96@users.sourceforge.net}
\end{Author}
\begin{Examples}
\begin{ExampleCode}
# resolve multiple matches.
data(pldata)
pl1 <- pldata[[1]]
pl2 <- pldata[[2]]
fbinary(pl1,pl2,error=400,ppm=TRUE,theta=1,weight=FALSE,method="rmi",uniq=TRUE,N=0)
# dont resolve multiple matches.
fbinary(pl1,pl2,error=400,ppm=TRUE,theta=0.2,weight=FALSE,method="rmi",uniq=FALSE)
fbinary(pl1,pl2,error=400,ppm=TRUE,theta=0.2,weight=FALSE,method="hg")
fbinary(pl1,pl2,error=400,ppm=TRUE,theta=0.2,weight=TRUE,method="gower")
fbinary(pl1,pl2,error=400,ppm=TRUE,theta=0.2,weight=TRUE,method="fm")
# seach with one peak-list in a list of peak-lists.
fbinary(pldata,pl1,error=400,ppm=TRUE,theta=0.2,weight=TRUE,method="fm")
# compute distances (dissimilarities) and cluster.
tmp <- fbinary(pldata,NULL,error=400,ppm=TRUE,theta=0.2,weight=TRUE,method="fm")
plot(hclust(tmp,method="average"))
\end{ExampleCode}
\end{Examples}

