R/WH_train_fit.r

Defines functions WH_train_fit

Documented in WH_train_fit

#' Train weights for WH, and output distance object
#' 
#' Train weights for WH using the given data, and fit the distance matrix for a input sequence.
#'
#' @param x input data in phyDat format
#'
#' @param X a list of k number of input data, X[[1]] ... X[[k]]. The ith data have sequence information as phyDat format in X[[i]][[1]], and tree information in X[[i]][[2]] as phylo format.
#'
#' @return a dist object
#'
#' @author Il-Youp Kwak (ikwak2@cau.ac.kr)
#'
#' @export

WH_train_fit <- function(x, X){
    InfoW = WH_train(X)  
    dist_weighted_hamming(x, InfoW, dropout=FALSE)
}

Try the DCLEAR package in your browser

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

DCLEAR documentation built on Sept. 14, 2023, 9:09 a.m.