Skip to content

Commit

Permalink
command line documentation
Browse files Browse the repository at this point in the history
rename the file name to be consistent wit the out file file sufflix
  • Loading branch information
cschin committed Feb 9, 2023
1 parent 755e522 commit 2bd65ea
Show file tree
Hide file tree
Showing 6 changed files with 44 additions and 3 deletions.
5 changes: 5 additions & 0 deletions pgr-bin/src/bin/pgr-fetch-seqs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,22 @@ use std::path::Path;
#[clap(author, version)]
#[clap(about = "list or fetch sequences from a pgr database", long_about = None)]
struct CmdOptions {
/// the prefix to a PGR-TK sequence database
pgr_db_prefix: String,

/// using the frg format for the sequence database (default to the AGC backend databse if not specified)
#[clap(long, default_value_t = false)]
frg_file: bool,

/// the regions file path
#[clap(short, long, default_value=None)]
region_file: Option<String>,

/// output file name
#[clap(short, long, default_value=None)]
output_file: Option<String>,

/// list all sequence source, contig names in the database
#[clap(long, default_value_t = false)]
list: bool,
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ use std::io::{BufRead, BufReader};
use std::path::Path;

#[derive(Parser, Debug)]
#[clap(name = "pgr-mdb")]
#[clap(name = "pgr-make-frgdb")]
#[clap(author, version)]
#[clap(about = "create pgr fragment minimizer db", long_about = None)]
#[clap(about = "create PGR-TK fragment minimizer database with frg format backend", long_about = None)]
struct CmdOptions {
// file contains the paths to the fastx files to load
/// the path to the file contains the paths to the fastx files to load
filepath: String,
prefix: String,
/// minimizer window size
Expand Down
2 changes: 2 additions & 0 deletions pgr-bin/src/bin/pgr-pbundle-bed2sorted.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ use std::{fs::File, path};
#[clap(author, version)]
#[clap(about = "sort the contig by bunldes", long_about = None)]
struct CmdOptions {
/// the path to the pricipal bundle bed file
bed_file_path: String,
/// the prefix of the output file
output_prefix: String,
}

Expand Down
13 changes: 13 additions & 0 deletions pgr-bin/src/bin/pgr-pbundle-bed2svg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,28 +11,41 @@ use svg::Document;
#[clap(author, version)]
#[clap(about = "generate SVG from a principal bundle bed file", long_about = None)]
struct CmdOptions {
/// the path to the pricipal bundle bed file
bed_file_path: String,
/// the prefix of the output file
output_prefix: String,
/// the prefix of the dendrogram file generated by pgr-pbundle-bed2dist
#[clap(long)]
ddg_file: Option<String>,
/// the path the annotation files
#[clap(long)]
annotations: Option<String>,
/// the path the annotation track file
#[clap(long)]
annotation_region_bedfile: Option<String>,
/// the track range in base pair count
#[clap(long, default_value_t = 100000)]
track_range: usize,
/// the track tick interval
#[clap(long, default_value_t = 10000)]
track_tick_interval: usize,
/// the track panel size in pixel
#[clap(long, default_value_t = 1600)]
track_panel_width: usize,
/// the left padding in pixel
#[clap(long)]
left_padding: Option<usize>,
/// the stroke boundary width
#[clap(long, default_value_t = 0.5)]
stroke_width: f32,
/// the stroke with for the annotation track
#[clap(long, default_value_t = 2.5)]
annotation_region_stroke_width: f32,
/// the anotation panel width
#[clap(long, default_value_t = 500.0)]
annotation_panel_width: f32,
/// the factor to increase the bounder width for highlighting repeatitive bundles
#[clap(long, default_value_t = 1.0)]
highlight_repeats: f32,
}
Expand Down
11 changes: 11 additions & 0 deletions pgr-bin/src/bin/pgr-pbundle-decomp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,24 +15,35 @@ use std::{
#[clap(author, version)]
#[clap(about = "take a fasta file and output the principal bundle decomposition though MAP Graph", long_about = None)]
struct CmdOptions {
/// the path to the input fasta file
fastx_path: String,
/// the prefix of the output files
output_prefix: String,
/// the path to the file that contains a list of contig name to be analyzed
#[clap(long, short, default_value = None)]
include: Option<String>,
/// the SHIMMER parameter w
#[clap(short, default_value_t = 48)]
w: u32,
/// the SHIMMER parameter k
#[clap(short, default_value_t = 56)]
k: u32,
/// the SHIMMER parameter r
#[clap(short, default_value_t = 4)]
r: u32,
/// the SHIMMER parameter minimum span length
#[clap(long, default_value_t = 12)]
min_span: u32,
/// minimum coverage to be included in principal bundles
#[clap(long, default_value_t = 0)]
min_cov: usize,
/// the minimum branch length to be included in the principal bundles
#[clap(long, default_value_t = 8)]
min_branch_size: usize,
/// the minimum local project bundle size to includes
#[clap(long, default_value_t = 2500)]
bundle_length_cutoff: usize,
/// merge two bundles with the same id with the specified length
#[clap(long, default_value_t = 10000)]
bundle_merge_distance: usize,
}
Expand Down
10 changes: 10 additions & 0 deletions pgr-bin/src/bin/pgr-query.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,28 +12,38 @@ use std::path::Path;
#[clap(author, version)]
#[clap(about = "query a pgr pangenome database and ouput the hits", long_about = None)]
struct CmdOptions {
/// the prefix to a PGR-TK sequence database
pgr_db_prefix: String,
/// the path to the query fasta file
query_fastx_path: String,
/// the prefix of the output file
output_prfix: String,

/// using the frg format for the sequence database (default to the AGC backend databse if not specified)
#[clap(long, default_value_t = false)]
frg_file: bool,

/// the gap penality factor for sparse alignments in the SHIMMER space
#[clap(long, short, default_value_t = 0.025)]
gap_penality_factor: f32,

/// merge hits with the specified distance
#[clap(long, short, default_value_t = 100000)]
merge_range_tol: usize,

/// the max count of SHIMMER used for the sparse alignemnt
#[clap(long, default_value_t = 128)]
max_count: u32,

/// the max count of SHIMMER in the query sequences used for the sparse alignemnt
#[clap(long, default_value_t = 128)]
max_query_count: u32,

/// the max count of SHIMMER in the targets sequences used for the sparse alignemnt
#[clap(long, default_value_t = 128)]
max_target_count: u32,

/// the span of the chain for building the sparse alignment directed acyclic graph
#[clap(long, default_value_t = 8)]
max_aln_chain_span: u32,
}
Expand Down

0 comments on commit 2bd65ea

Please sign in to comment.