Skip to content

Commit

Permalink
version 0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
natir committed Oct 16, 2018
1 parent c14b20e commit d660c82
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 9 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "fpa_lr"
version = "0.2.0"
version = "0.3.0"
authors = ["Pierre Marijon <pierre.marijon@inria.fr>"]

description = "fpa filter long read mapping information to save disk space"
Expand Down
11 changes: 10 additions & 1 deletion Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ minimap2 long_read.fasta long_read.fasta | fpa -d | gzip - > long_read_dovetail.
minimap2 long_read.fasta long_read.fasta | fpa -l 500 -L 2000 > match_between_500_2000.paf
minimap2 long_read.fasta long_read.fasta | fpa -s -m read_1 > no_self_match_no_read_1.paf
minimap2 long_read.fasta long_read.fasta | fpa -s -r rename.csv > no_self_match_renamed_read_1.paf
minimap2 long_read.fasta long_read.fasta | fpa -s -r rename.csv -g gfa1 > no_self_match_renamed_read_1.gfa
```

### Rename option
Expand All @@ -43,6 +44,14 @@ If the name of the read does not exist in the file it will not be replaced.

If the path passed as parameter does not exist, the names will automatically be replaced by a number, a file like above example will be created.

### Output mode

You can get an output in gfa format with the -o option (--output-mode), two modes are available:
- basic: the output and in the format that the input
- gfa1: the output is in gfa1 format

In gfa1 mode options -C and -I indicate that containments and internalmatches are included in the gfa (default option enabled), -c and -i indicate that containments and internalmatches should not be included.

## Rationale

Long Read mapping tools provides all match they found in read dataset, for many usage some of match aren't usfull, this programme provide some filter to remove it.
Expand Down Expand Up @@ -80,7 +89,7 @@ conda install fpa
```
git clone https://github.com/natir/fpa.git
cd fpa
git checkout v0.2
git checkout v0.3
cargo build
cargo test
Expand Down
12 changes: 6 additions & 6 deletions src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,32 +34,32 @@ use clap::{App, Arg, ArgMatches};

pub fn parser<'a>() -> ArgMatches<'a> {
App::new("fpa")
.version("0.2 Beedrill")
.version("0.3 Meowth")
.author("Pierre Marijon <pierre.marijon@inria.fr>")
.about("fpa take long read mapping information and filter them")
.arg(Arg::with_name("delete_containment")
.short("c")
.display_order(10)
.long("delete-containment")
.help("If match are containment match is discard")
.help("If match are containment match is discard, in gfa1 mode containment is not included")
)
.arg(Arg::with_name("keep_containment")
.short("C")
.display_order(20)
.long("keep-containment")
.help("Only containment match is keeped")
.help("Only containment match is keeped, in gfa1 mode containment is included")
)
.arg(Arg::with_name("delete_internalmatch")
.short("i")
.display_order(30)
.long("delete-internalmatch")
.help("If match are an internal match is discard")
.help("If match are an internal match is discard, in gfa1 mode internalmatch is not included")
)
.arg(Arg::with_name("keep_internalmatch")
.short("I")
.display_order(40)
.long("keep-internalmatch")
.help("Only internal match overlap is keeped")
.help("Only internal match overlap is keeped, in gfa1 mode internalmatch is included")
)
.arg(Arg::with_name("delete_dovetail")
.short("d")
Expand Down Expand Up @@ -144,7 +144,7 @@ pub fn parser<'a>() -> ArgMatches<'a> {
.possible_values(&["paf", "mhap"])
)
.arg(Arg::with_name("mode")
.short("g")
.short("o")
.long("output-mode")
.display_order(120)
.takes_value(true)
Expand Down

0 comments on commit d660c82

Please sign in to comment.