Skip to content

Commit

Permalink
fixes boot error
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuailevy committed Nov 20, 2024
1 parent b837e31 commit 1f8fa8a
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions freyja/_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -521,10 +521,14 @@ def variants(bamfile, ref, variants, depths, refname, minq, annot, varthresh):
help='Pathogen of interest.' +
'Not used if using --barcodes option.',
show_default=True)
@click.option('--autoadapt', default=False,
is_flag=True,
help='use error profile to set adapt',
show_default=True)
def boot(variants, depths, output_base, eps, barcodes, meta,
nb, nt, boxplot, confirmedonly, lineageyml, depthcutoff,
rawboots, relaxedmrca, relaxedthresh, bootseed,
solver, pathogen):
solver, pathogen, autoadapt):
"""
Perform bootstrapping method for freyja using VARIANTS and DEPTHS
"""
Expand Down Expand Up @@ -560,8 +564,11 @@ def boot(variants, depths, output_base, eps, barcodes, meta,
print('building mix/depth matrices')
# assemble data from (possibly) mixed samples
covcut = 10 # set value, coverage estimate not returned to user from boot
mix, depths_, cov = build_mix_and_depth_arrays(variants, depths, muts,
covcut)
mix, depths_, cov, adapt = build_mix_and_depth_arrays(variants,
depths,
muts,
covcut,
autoadapt)
print('demixing')
df_barcodes, mix, depths_ = reindex_dfs(df_barcodes, mix, depths_)
lin_df, constell_df = perform_bootstrap(df_barcodes, mix, depths_,
Expand Down

0 comments on commit 1f8fa8a

Please sign in to comment.