\HeaderA{nuID2RefSeqID}{Map nuID to RefSeq ID}{nuID2RefSeqID}
\keyword{methods}{nuID2RefSeqID}
\keyword{utilities}{nuID2RefSeqID}
\begin{Description}\relax
Map nuID to RefSeq ID based on IDMapping libraries.
\end{Description}
\begin{Usage}
\begin{verbatim}
nuID2RefSeqID(nuID = NULL, lib.mapping, filterTh = c(Strength1 = 95, Uniqueness = 95), returnAllInfo = FALSE)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{nuID}] a vector of nuIDs. If it is NULL, all mappings will be returned. 
\item[\code{lib.mapping}] the ID mapping library 
\item[\code{filterTh}] the mapping quality filtering threshold used to filter the ID mapping. 
\item[\code{returnAllInfo}] determine to return the detailed mapping information or just the matched RefSeq IDs 
\end{ldescription}
\end{Arguments}
\begin{Details}\relax
This function is based on the return of \code{\LinkA{getNuIDMappingInfo}{getNuIDMappingInfo}} function. It uses mapping quality information to filter out the bad mappings. The names of "filterTh" are basically the field names of "nuID\_MappingInfo" table, which include 'Strength1', 'Strength2', 'Uniqueness' and 'Total hits'. For the definition of these metrics, please refer to the IDMapping library or see the reference website.
\end{Details}
\begin{Value}
returns the matched RefSeq IDs or a data.frame with each row corresponding to an input nuID (when "returnAllInfo" is TRUE).
\end{Value}
\begin{Author}\relax
Warren Kibbe, Pan Du, Simon Lin
\end{Author}
\begin{References}\relax
https://prod.bioinformatics.northwestern.edu/nuID/
\end{References}
\begin{SeeAlso}\relax
See Also \code{\LinkA{getNuIDMappingInfo}{getNuIDMappingInfo}}
\end{SeeAlso}
\begin{Examples}
\begin{ExampleCode}
        ## load example data
        data(example.lumi)
        if (require(lumiHumanIDMapping)) {
                nuIDs <- featureNames(example.lumi)
                mappingInfo <- nuID2RefSeqID(nuIDs, lib.mapping='lumiHumanIDMapping')
                head(mappingInfo)
        }
\end{ExampleCode}
\end{Examples}

