View source: R/mk_subread_index.R
mk_subread_index | R Documentation |
This function is a wrapper for the Rsubread::buildindex
function. It
will generate one or more Subread indexes from a .fasta file. If the library
is too large (default >4GB) it will automatically be split into multiple
indexes, with _1, _2, etc at the end of the ref_lib basename.
mk_subread_index(ref_lib, split = 4, mem = 8000, quiet = TRUE)
ref_lib |
The name/location of the reference library file, in (uncompressed) .fasta format. |
split |
The maximum allowed size of the genome file (in GB). If the
|
mem |
The maximum amount of memory (in MB) that can be used by the index generation process (used by the Rsubread::buildindex function). |
quiet |
Turns off most messages. Default is |
Creates one or more Subread indexes for the supplied reference .fasta
file. If multiple indexes are created, the libraries will be named the
ref_lib
basename + "_1", "_2", etc. The function returns the names of the
folders holding these files.
#### Create a subread index from the example reference library
## Create a temporary directory to store the reference library
ref_temp <- tempfile()
dir.create(ref_temp)
## Download reference genome
out_fasta <- download_refseq('Orthoebolavirus zairense', reference = FALSE,
representative = FALSE, out_dir = ref_temp,
compress = TRUE, patho_out = FALSE,
caching = TRUE)
## Make subread index of reference library
mk_subread_index(out_fasta)
unlink(ref_temp)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.