From 597617c84b3bbab343e8634e78312625a87a0780 Mon Sep 17 00:00:00 2001 From: Oddant1 Date: Thu, 22 Aug 2024 14:48:17 -0700 Subject: [PATCH] More modifications --- q2_boots/_alpha.py | 13 ++++++------- q2_boots/_beta.py | 20 ++++++++++---------- 2 files changed, 16 insertions(+), 17 deletions(-) diff --git a/q2_boots/_alpha.py b/q2_boots/_alpha.py index ea1b72a..c8cd546 100644 --- a/q2_boots/_alpha.py +++ b/q2_boots/_alpha.py @@ -45,15 +45,14 @@ def alpha_collection(ctx, table, sampling_depth, metric, n, def alpha(ctx, table, sampling_depth, metric, n, replacement, phylogeny=None, average_method='median'): - alpha_collection_action = ctx.get_action("boots", "alpha_collection") alpha_average_action = ctx.get_action('boots', 'alpha_average') - sample_data = alpha_collection_action(table=table, - sampling_depth=sampling_depth, - phylogeny=phylogeny, - metric=metric, - n=n, - replacement=replacement) + sample_data, = alpha_collection_action(table=table, + sampling_depth=sampling_depth, + phylogeny=phylogeny, + metric=metric, + n=n, + replacement=replacement) result, = alpha_average_action(sample_data, average_method) return result diff --git a/q2_boots/_beta.py b/q2_boots/_beta.py index 6f83303..aa97a01 100644 --- a/q2_boots/_beta.py +++ b/q2_boots/_beta.py @@ -76,16 +76,16 @@ def beta(ctx, table, metric, sampling_depth, n, replacement, variance_adjusted=_METRIC_MOD_DEFAULTS['variance_adjusted']): beta_collection_action = ctx.get_action('boots', 'beta_collection') beta_average_action = ctx.get_action('boots', 'beta_average') - dms = beta_collection_action(table=table, - phylogeny=phylogeny, - metric=metric, - sampling_depth=sampling_depth, - n=n, - pseudocount=pseudocount, - replacement=replacement, - variance_adjusted=variance_adjusted, - alpha=alpha, - bypass_tips=bypass_tips) + dms, = beta_collection_action(table=table, + phylogeny=phylogeny, + metric=metric, + sampling_depth=sampling_depth, + n=n, + pseudocount=pseudocount, + replacement=replacement, + variance_adjusted=variance_adjusted, + alpha=alpha, + bypass_tips=bypass_tips) result, = beta_average_action(dms, average_method) return result