@@ -809,7 +809,7 @@ check_if_any_NA = function(input.df, sample_column, gene_column, value_column, s
809809# ' @importFrom magrittr multiply_by
810810# ' @importFrom purrr map2
811811# ' @importFrom purrr map_int
812- # ' @importFrom ttBulk normalise_abundance
812+ # ' @importFrom ttBulk scale_abundance
813813# '
814814# ' @param my_df A tibble including a gene name column | sample name column | read counts column | covariates column
815815# ' @param formula A formula
@@ -1149,7 +1149,7 @@ format_input = function(input.df, formula, sample_column, gene_column, value_col
11491149# ' @importFrom magrittr multiply_by
11501150# ' @importFrom purrr map2
11511151# ' @importFrom purrr map_int
1152- # ' @importFrom ttBulk normalise_abundance
1152+ # ' @importFrom ttBulk scale_abundance
11531153# ' @importFrom benchmarkme get_ram
11541154# ' @importFrom magrittr multiply_by
11551155# '
@@ -1289,7 +1289,7 @@ ppc_seq = function(input.df,
12891289 # Build better scales for the inference
12901290 exposure_rate_multiplier =
12911291 my_df %> %
1292- normalise_abundance (!! sample_column ,!! gene_column ,!! value_column ) %> %
1292+ scale_abundance (!! sample_column ,!! gene_column ,!! value_column ) %> %
12931293 distinct(!! sample_column , TMM , multiplier ) %> %
12941294 mutate(l = multiplier %> % log ) %> %
12951295 summarise(l %> % sd ) %> %
@@ -1298,7 +1298,7 @@ ppc_seq = function(input.df,
12981298 # Build better scales for the inference
12991299 intercept_shift_scale =
13001300 my_df %> %
1301- normalise_abundance (!! sample_column ,!! gene_column ,!! value_column ) %> %
1301+ scale_abundance (!! sample_column ,!! gene_column ,!! value_column ) %> %
13021302 mutate(cc =
13031303 !! as.symbol(sprintf(
13041304 " %s normalised" , quo_name(value_column )
@@ -1376,6 +1376,7 @@ ppc_seq = function(input.df,
13761376 adj_prob_theshold = adj_prob_theshold_2 , # If check only deleterious is one side test
13771377 # * 2 because we just test one side of the distribution
13781378 how_many_posterior_draws = how_many_posterior_draws_2 ,
1379+ pass_fit = pass_fit ,
13791380 to_exclude = to_exclude ,
13801381 save_generated_quantities = save_generated_quantities ,
13811382 tol_rel_obj = tol_rel_obj ,
@@ -1387,11 +1388,10 @@ ppc_seq = function(input.df,
13871388 merge_results(res_discovery , res_test , formula , gene_column , value_column , sample_column , do_check_only_on_detrimental ) %> %
13881389
13891390 # Add fit attribute if any
1390- add_attr(res_test %> % attr(" fit" ), " fit" ) %> %
1391+ add_attr(res_discovery %> % attr(" fit" ), " fit 1" ) %> %
1392+ add_attr(res_test %> % attr(" fit" ), " fit 2" ) %> %
13911393
13921394 # Add total draws
13931395 add_attr(res_test %> % attr(" total_draws" ), " total_draws" )
13941396
1395-
1396-
13971397}
0 commit comments