-
Notifications
You must be signed in to change notification settings - Fork 95
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sleuth "Advanced options" #168
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ed using an independent filtering method
+ this allows the use different weights with the observed means of transcripts for the lancaster method + this prevents errors when a sleuth-ALR transformation is used
+ Changed API for 'transformation_fun' and 'transformation_fun_tpm' to 'transform_fun_counts' and 'transform_fun_tpm' respectively + Added public API for the 'norm_fun_counts' and 'norm_fun_tpm' so that users can see how the data was normalized when viewing a sleuth object. + Added error handling if the user attempts to change 'norm_fun_counts' or 'norm_fun_tpm' manually. + Added new 'normalize' boolean to skip the normalization steps, which also skips the rest of the downstream processing (bootstrap summarization, transformation, etc.) + Moved several of the sleuth_prep options to a new section of 'advanced options'. These are now handled by the '...' argument. This includes options for summarizing the bootstraps ('read_bootstrap_tpm', 'extra_bootstrap_summary', 'max_bootstrap'), normalizing the data ('normalize' boolean, 'norm_fun_counts', 'norm_fun_tpm'), transforming the data ('transform_fun_counts', 'transform_fun_tpm'), and the old 'gene_mode' for counts aggregation. Followed the example for advanced options used by the 'polyester' package for its 'simulate_experiment' function. + Added sanity checks for the mutually exclusive 'gene_mode' & 'pval_aggregate' modes for gene-level aggregation. 'pval_aggregate' is the default mode if 'aggregation_column' is set. If the user tries to change either gene_mode or pval_aggregate manually, they receive warning if these two modes conflict and if 'gene_column' has not been set. + Changed how the sleuth object handles when 'transform_fun_counts' or 'transform_fun_tpm' are changed manually. Now it throws an error if nothing has been fit, preventing the user from changing the listed transformation function. This is so users can always see how the data was transformed when viewing fits within a sleuth object.
+ Specifies documentation for the 'which_var' argument. + Adds explicit documentation for the additional options to 'sliding_window_grouping': 'n_bins', 'lwr', and 'upr'.
+ Discuss the interpretation of the 'b' value from Wald test results. + Discuss the warning if gene aggregation is done with transcript-level target_mappings. + Discuss the two aggregation modes. + Discuss the advanced option 'weight_func' for weighting the lancaster method. + Add the expected columns to the specification of the results if a user does 'pval_aggregate = TRUE'
+ now those packages can move to the 'imports' section of the DESCRIPTION + this addresses issue pachterlab#56
…cter columns + this prevents warnings introduced when the supplied target_mapping had factors instead + this handles bugs seen in issues pachterlab#76 and pachterlab#169
JFC, @warrenmcg. This is a massive PR. I didn't think you were going to go through all of this so carefully -- thanks for that. It looks great! |
PS: thanks for dealing with the |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi @pimentel,
Here are my suggested changes to the sleuth API and Documentation:
New arguments
filter_target_id
option tosleuth_prep
, to allow users to specify a list of target_ids to filter using some independent method. This is recommended if the preferred filtering method requires a matrix-wide transformation (e.g. edgeR's CPM filter) or otherwise requires assessing multiple features simultaneously, sincesleuth_prep
filtering step is built to only assess features one at a time.normalize
option tosleuth_prep
that allows the user to skip the normalization steps (and all subsequent steps) if set toFALSE
. This severely reduces the functionality of thesleuth
object for most downstream applications, but could be useful in certain situations (e.g. quickly checking a custom filter; quickly checking the raw data or summary of the kallisto objects; etc).weight_func
option tosleuth_results
, to specify a custom weighting function that acts on the mean observations for each transcript when doing p-value aggregation.Changed API
transformation_function
andtransformation_function_tpm
totransform_fun_counts
andtransform_fun_tpm
, respectively, for clarity and brevity.sleuth_prep
. Move several features to "advanced options" using...
and the Details section of the documentation for details. The following features were moved:filter_target_id
,filter_fun
,norm_fun_counts
,norm_fun_tpm
,extra_bootstrap_summary
,read_bootstrap_tpm
,max_bootstrap
,transform_fun_counts
, andtransform_fun_tpm
.sleuth_fit
. Movedwhich_var
and thesliding_window_grouping
extra options to...
with details in the Details section of the documentation.sleuth_results
, with theweight_func
hidden in...
, but described in detail in the Details section of the documentation.Other small changes:
bs_sigma_summary
, since it assumes that the bootstraps are summarized using the method in versions <= 0.28.1.