Skip to content

Commit 7022114

Browse files
committed
Add -m as short option for scaffold filter
Now can use -n and -m together for cleaner syntax: -n 1:1 -m 1:1 (aggressive filtering) -n many -m 1:1 (default) -n 1 -m 1 (1:many on both) Updated documentation to reflect this change.
1 parent b14d1b7 commit 7022114

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

CLAUDE.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ The filtering process follows this exact sequence:
8787
4. **Scaffold Filter** (default: 1:1)
8888
- Apply plane sweep filtering to the SCAFFOLD chains
8989
- Respects PanSN prefix grouping when `-Y` is set
90-
- Controlled by `--scaffold-filter` (default: "1:1")
90+
- Controlled by `-m/--scaffold-filter` (default: "1:1")
9191
- Options: "1:1", "1" (same as "1:∞"), "N" (no filtering)
9292
- Keeps best scaffolds per query/target pair within each prefix group
9393

@@ -101,7 +101,7 @@ The filtering process follows this exact sequence:
101101
## Key Parameters
102102

103103
- `-n/--num-mappings`: Primary mapping filter before scaffolds (default: "many" = no filtering)
104-
- `--scaffold-filter`: Filter for scaffold chains (default: "1:1")
104+
- `-m/--scaffold-filter`: Filter for scaffold chains (default: "1:1")
105105
- `-s/--scaffold-mass`: Minimum scaffold length (default: 10kb)
106106
- `-j/--scaffold-jump`: Maximum gap to merge mappings into scaffolds (default: 10kb)
107107
- `-d/--scaffold-dist`: Maximum distance for rescue (default: 20kb)
@@ -148,12 +148,12 @@ This would make the pipeline stages explicit and composable, reducing confusion
148148

149149
1. **Default (wfmash-like)**: No pre-filtering, 1:1 scaffold filtering
150150
```
151-
sweepga -S 10000 # Creates scaffolds, keeps best per genome pair
151+
sweepga # Creates scaffolds, keeps best per chromosome pair
152152
```
153153

154154
2. **Aggressive filtering**: 1:1 pre-filtering, 1:1 scaffold filtering
155155
```
156-
sweepga -S 10000 -n 1:1 --scaffold-filter 1:1
156+
sweepga -n 1:1 -m 1:1
157157
```
158158

159159
3. **Pre-filter only**: No scaffolding
@@ -163,7 +163,7 @@ This would make the pipeline stages explicit and composable, reducing confusion
163163

164164
4. **Keep more mappings**: 1:∞ for both filters
165165
```
166-
sweepga -S 10000 -n 1 --scaffold-filter 1 # "1" is shorthand for "1:∞"
166+
sweepga -n 1 -m 1 # "1" is shorthand for "1:∞"
167167
```
168168

169169
## Key Differences from Original Description

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ grep -c "st:Z:rescued" data/scerevisiae8.filtered.paf # Rescued mappings
7070
- **No pre-filtering** (`-n many`): All mappings participate in scaffold building
7171
- **Scaffold creation** (`-j 10k`): Merge mappings within 10kb gaps
7272
- **Min scaffold** (`-s 10k`): Scaffolds must be ≥10kb
73-
- **1:1 scaffold filter** (`--scaffold-filter 1:1`): Keep best scaffold per chromosome pair
73+
- **1:1 scaffold filter** (`-m 1:1`): Keep best scaffold per chromosome pair
7474
- **Rescue distance** (`-d 20k`): Rescue mappings within 20kb of scaffolds
7575

7676
## Parameters
@@ -91,7 +91,7 @@ grep -c "st:Z:rescued" data/scerevisiae8.filtered.paf # Rescued mappings
9191

9292
`-d/--scaffold-dist` sets the maximum Euclidean distance for rescue (default 20k). Mappings further than this from any scaffold anchor are discarded.
9393

94-
`--scaffold-filter` controls scaffold filtering (default "1:1"). Options: "1:1", "1" (1:many), "many" (no filter).
94+
`-m/--scaffold-filter` controls scaffold filtering (default "1:1"). Options: "1:1", "1" (1:many), "many" (no filter).
9595

9696
### Chain Annotations
9797

src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ struct Args {
9696
num_mappings: String,
9797

9898
/// Scaffold filter: "1:1" (best), "M:N" (top M per query, N per target; ∞/many for unbounded)
99-
#[clap(long = "scaffold-filter", default_value = "1:1")]
99+
#[clap(short = 'm', long = "scaffold-filter", default_value = "1:1")]
100100
scaffold_filter: String,
101101

102102
/// Scaffold jump (gap) distance. 0 = disable scaffolding (plane sweep only), >0 = enable scaffolding

0 commit comments

Comments
 (0)