R/jaq2label.R

Defines functions jaq2label

Documented in jaq2label

jaq2label <-
function( jaq, phased = TRUE){
    
    out <- allJaq()

    label <- numeric( length(jaq ))
    sel <- ifelse( phased, 2,3 )
    for( i in 1:length(jaq)) label[i] <- min( out[ out[,sel]==jaq[i], 1],
                                             na.rm = TRUE)


    if(!phased && length( intersect( jaq, c(3, 5, 7, 8 ))) > 0 )
        warning( "jaq9 goes to minimum label" ) 
    
    return( label )
}

Try the IBDLabels package in your browser

Any scripts or data that you put into this service are public.

IBDLabels documentation built on May 2, 2019, 9:58 a.m.