Skip to contents

asap_tbl() returns species partition hypothesis estimated by ASAP software https://bioinfo.mnhn.fr/abi/public/asap/.

Usage

asap_tbl(
  infile,
  exe = NULL,
  haps = NULL,
  model = 3,
  outfolder = NULL,
  webserver = NULL,
  delimname = "asap"
)

Source

Puillandre N., Brouillet S., Achaz G. 2021. ASAP: assemble species by automatic partitioning. Molecular Ecology Resources 21:609–620.

Arguments

infile

Path to fasta file.

exe

Path to an ASAP executable.

haps

Optional. A vector of haplotypes to keep into the tbl_df.

model

An integer specifying evolutionary model to be used. Available options are:

  • 0: Kimura-2P

  • 1: Jukes-Cantor (default)

  • 2: Tamura-Nei

  • 3: simple distance (p-distance)

outfolder

Path to output folder. Default to NULL. If not specified, a temporary location is used.

webserver

A .csv file containing ASAP results obtained from a webserver. Default to NULL.

delimname

Character. String to rename the delimitation method in the table. Default to 'asap'.

Value

an object of class tbl_df

Details

asap_tbl() relies on system to invoke ASAP software through a command-line interface. Hence, you must have the software available as an executable file on your system in order to use this function properly. asap_tbl() saves all output files in outfolder and imports the first partition file generated to Environment. Alternatively, asap_tbl() can parse a .csv file obtained from webserver such as https://bioinfo.mnhn.fr/abi/public/asap/asapweb.html.

Author

Nicolas Puillandre, Sophie Brouillet, Guillaume Achaz.

Examples


# \donttest{

#' # get path to fasta file
path_to_file <- system.file("extdata/geophagus.fasta", package = "delimtools")

# run ASAP
asap_df <- asap_tbl(infile = path_to_file, exe= "/usr/local/bin/asap", model= 3)
#> Error in asap_tbl(infile = path_to_file, exe = "/usr/local/bin/asap",     model = 3): Error: Please provide a valid path to the ASAP executable file.

# check
asap_df
#> Error: object 'asap_df' not found

# }