importAllelicPAM: Import the allelic presence-absence matrix (PAM) of bacterial...

View source: R/func__importAllelicPAM.R

importAllelicPAMR Documentation

Import the allelic presence-absence matrix (PAM) of bacterial genes.

Description

This function reads the allelic p/a matrix and returns a list of relevant matrices.

Usage

importAllelicPAM(
  pam,
  pam.delim = "\t",
  outliers = NULL,
  min.count = 1,
  alleles.inc = NULL,
  output.y = "",
  sample.order = NULL,
  skip = TRUE
)

Arguments

pam

either the final PAM or the file name of a raw PAM created by the PAMmaker pipeline. First column: Sample; other columns: allele identifiers.

pam.delim

a single character for the delimiter in the text file of the allelic PAM.

outliers

a vector of isolate names to be excluded from rows of the allelic PAM.

min.count

the minimal number of times that an allele occurs in all isolates excluding outliers. By default, only alleles that do not occur at all are removed (min.count = 1). When min.count = 2, isolate-specific alleles are removed as well.

alleles.inc

a vector of allele names to be included for columns of the allelic PAM.

output.y

path to the output file for the centred pattern matrix Y. Keep output.y = "" to prevent the function from printing the matrix. In this case, only a list is returned to the user.

sample.order

a vector of isolate names for the PAM to be matched with. It can be used to filter the allelic PAM for in-group isolates.

skip

wheter to skip overwriting existant output files.

Author(s)

Yu Wan (wanyuac@126.com)


wanyuac/GeneMates documentation built on Aug. 12, 2022, 7:37 a.m.