News and Announcements » |
Description:
This script provides a framework for paired-difference testing (i.e., analysis of data generated under a pre/post experimental design). In a pre/post experimental design, individuals are sampled before and after some ‘treatment’. This code plots differences in values in the sample metadata (i.e., the mapping file) or observation counts in a BIOM table, and runs a (Bonferroni-corrected) one sample t-test on each sample metadata category or BIOM observation to determine if the mean of each distribution of pre/post differences differs from zero. If ‘None’ appears for the t score and p-values, this often means that the distribution of differences contained no variance, so the t-test could not be run. This can happen, for example, if the value passed for –valid_states is so restrictive that only a single sample is retained for analysis.
Usage: identify_paired_differences.py [options]
Input Arguments:
Note
[REQUIRED]
[OPTIONAL]
Output:
The output of this script is plots of pre/post differences and associated statistics.
Generate plots and stats for one category from the mapping file where the y-axis should be consistent across plots and the lines in the plots should be light blue.:
identify_paired_differences.py -m map.txt --metadata_categories 'Streptococcus Abundance' --state_category TreatmentState --state_values Pre,Post --individual_id_category PersonalID -o taxa_results --ymin 0 --ymax 60 --line_color '#eeefff'
Generate plots and stats for three categories from the mapping file.:
identify_paired_differences.py -m map.txt --metadata_categories 'Streptococcus Abundance,Phylogenetic Diversity,Observed OTUs' --state_category TreatmentState --state_values Pre,Post --individual_id_category PersonalID -o taxa_and_alpha_results
Generate plots for all observations in a biom file:
identify_paired_differences.py -m map.txt -b otu_table.biom --state_category TreatmentState --state_values Pre,Post --individual_id_category PersonalID -o otu_results
Generate plots for all observations in a biom file, but only including samples from individuals whose ‘TreatmentResponse’ was ‘Improved’ (as defined in the mapping file).:
identify_paired_differences.py -m map.txt -b otu_table.biom --state_category TreatmentState --state_values Pre,Post --individual_id_category PersonalID -o otu_results_improved_only --valid_states TreatmentResponse:Improved