View source: R/write_dummy_data.R
create_dummy_data | R Documentation |
Create random sequences from predefined vocabulary and write to fasta file.
create_dummy_data(
file_path,
num_files,
header = "header",
seq_length,
num_seq,
fasta_name_start = "file",
write_to_file_path = FALSE,
prob = NULL,
vocabulary = c("a", "c", "g", "t")
)
file_path |
Output directory; can also be a file name but only possible if |
num_files |
Number of files to create. |
header |
Fasta header name. |
seq_length |
Length of one sequence. If vector longer than 1, will randomly sample from that vector. |
num_seq |
Number of sequences per file. |
fasta_name_start |
Beginning string of file name. Output files are named fasta_name_start + _i.fasta where i is an integer index. |
write_to_file_path |
Whether to write output directly to |
prob |
Probability of each character in the |
vocabulary |
Set of characters to sample sequences from. |
None. Writes data to files.
path_output <- tempfile()
dir.create(path_output)
create_dummy_data(file_path = path_output,
num_files = 3,
seq_length = 11,
num_seq = 5,
vocabulary = c("a", "c", "g", "t"))
list.files(path_output)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.