[med-svn] r13904 - in trunk/packages/qiime/trunk/debian: . patches.bak scripts.bak scripts.bak/shell source.bak
Timothy Booth
tbooth-guest at alioth.debian.org
Mon Jun 10 17:23:58 UTC 2013
Author: tbooth-guest
Date: 2013-06-10 17:23:58 +0000 (Mon, 10 Jun 2013)
New Revision: 13904
Added:
trunk/packages/qiime/trunk/debian/patches.bak/
trunk/packages/qiime/trunk/debian/patches.bak/broken
trunk/packages/qiime/trunk/debian/patches.bak/check_config_file_in_new_location.patch
trunk/packages/qiime/trunk/debian/patches.bak/fix_binary_helper_location.patch
trunk/packages/qiime/trunk/debian/patches.bak/fix_path_for_support_files
trunk/packages/qiime/trunk/debian/patches.bak/fix_path_for_support_files_the_hard_way
trunk/packages/qiime/trunk/debian/patches.bak/fix_t_test_bug
trunk/packages/qiime/trunk/debian/patches.bak/make_qiime_accept_new_rdp_classifier
trunk/packages/qiime/trunk/debian/patches.bak/series
trunk/packages/qiime/trunk/debian/scripts.bak/
trunk/packages/qiime/trunk/debian/scripts.bak/qiime
trunk/packages/qiime/trunk/debian/scripts.bak/qiime_config
trunk/packages/qiime/trunk/debian/scripts.bak/shell/
trunk/packages/qiime/trunk/debian/scripts.bak/shell/.bashrc
trunk/packages/qiime/trunk/debian/scripts.bak/shell/.zshrc
trunk/packages/qiime/trunk/debian/scripts.bak/shell/qiime_environment
trunk/packages/qiime/trunk/debian/scripts.bak/shell/qiime_help
trunk/packages/qiime/trunk/debian/scripts.bak/uclust
trunk/packages/qiime/trunk/debian/source.bak/
trunk/packages/qiime/trunk/debian/source.bak/format
Log:
still trying to get SVN to play ball
Added: trunk/packages/qiime/trunk/debian/patches.bak/broken
===================================================================
--- trunk/packages/qiime/trunk/debian/patches.bak/broken (rev 0)
+++ trunk/packages/qiime/trunk/debian/patches.bak/broken 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,39 @@
+Description: <short summary of the patch>
+ TODO: Put a short summary on the line above and replace this paragraph
+ with a longer explanation of this change. Complete the meta-information
+ with other relevant fields (see below for details). To make it easier, the
+ information below has been extracted from the changelog. Adjust it or drop
+ it.
+ .
+ qiime (1.5.0+repack-2ubuntu11) precise; urgency=low
+ .
+ * The support_files patch only solved part of the problem,
+ so trying a different tack.
+Author: Tim Booth <tbooth at ceh.ac.uk>
+
+---
+The information above should follow the Patch Tagging Guidelines, please
+checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
+are templates for supplementary fields that you might want to add:
+
+Origin: <vendor|upstream|other>, <url of original patch>
+Bug: <url in upstream bugtracker>
+Bug-Debian: http://bugs.debian.org/<bugnumber>
+Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
+Forwarded: <no|not-needed|url proving that it has been forwarded>
+Reviewed-By: <name and email of someone who approved the patch>
+Last-Update: <YYYY-MM-DD>
+
+--- qiime-1.5.0+repack.orig/qiime/check_id_map.py
++++ qiime-1.5.0+repack/qiime/check_id_map.py
+@@ -108,8 +108,8 @@ def check_mapping_file(mapping_fp,
+
+ # Write javascript file necessary for mouseover tooltips.
+ # move javascript file to javascript output directory
+- copyfile(join(qiime_dir,'qiime','support_files',\
+- 'js/overlib.js'), join(output_dir,'overlib.js'))
++ copyfile('/usr/lib/qiime/support_files/js/overlib.js'),\
++ join(output_dir,'overlib.js'))
+
+ corrected_mapping_data = correct_mapping_data(mapping_data,
+ header, char_replace)
Added: trunk/packages/qiime/trunk/debian/patches.bak/check_config_file_in_new_location.patch
===================================================================
--- trunk/packages/qiime/trunk/debian/patches.bak/check_config_file_in_new_location.patch (rev 0)
+++ trunk/packages/qiime/trunk/debian/patches.bak/check_config_file_in_new_location.patch 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,15 @@
+We've moved the default config file, so tell this script to look in the new
+location. See the next patch for other path fixes related to support_files
+
+--- a/scripts/print_qiime_config.py
++++ b/scripts/print_qiime_config.py
+@@ -248,8 +248,7 @@
+ """local qiime_config has no extra params"""
+
+ qiime_project_dir = get_qiime_project_dir()
+- orig_config = parse_qiime_config_file(open(qiime_project_dir +
+- '/qiime/support_files/qiime_config'))
++ orig_config = parse_qiime_config_file(open('/etc/qiime/qiime_config'))
+
+ #check the env qiime_config
+ qiime_config_env_filepath = getenv('QIIME_CONFIG_FP')
Added: trunk/packages/qiime/trunk/debian/patches.bak/fix_binary_helper_location.patch
===================================================================
--- trunk/packages/qiime/trunk/debian/patches.bak/fix_binary_helper_location.patch (rev 0)
+++ trunk/packages/qiime/trunk/debian/patches.bak/fix_binary_helper_location.patch 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,14 @@
+--- a/qiime/denoiser/utils.py
++++ b/qiime/denoiser/utils.py
+@@ -42,8 +42,9 @@
+ def get_flowgram_ali_exe():
+ """Return the path to the flowgram alignment prog
+ """
+- fp = get_qiime_scripts_dir() + "/FlowgramAli_4frame"
+- return fp
++ #fp = get_qiime_scripts_dir() + "/FlowgramAli_4frame"
++ #return fp
++ return "/usr/lib/qiime/support_files/denoiser/bin/FlowgramAli_4frame"
+
+ def check_flowgram_ali_exe():
+ """Check if we have a working FlowgramAligner"""
Added: trunk/packages/qiime/trunk/debian/patches.bak/fix_path_for_support_files
===================================================================
--- trunk/packages/qiime/trunk/debian/patches.bak/fix_path_for_support_files (rev 0)
+++ trunk/packages/qiime/trunk/debian/patches.bak/fix_path_for_support_files 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,18 @@
+This may be a much simpler fix than patching every single mention
+of support_files, but I'm not sure what else this function is used
+to find?
+
+--- a/qiime/util.py
++++ b/qiime/util.py
+@@ -295,8 +295,9 @@
+ # Get the directory containing util.py
+ current_dir_path = dirname(current_file_path)
+ # Return the directory containing the directory containing util.py
+- return dirname(current_dir_path)
+-
++ # In Debian what we actually want is /usr/lib/[qiime]
++ return "/usr/lib"
++
+ def get_qiime_scripts_dir():
+ """ Returns the QIIME scripts directory
+
Added: trunk/packages/qiime/trunk/debian/patches.bak/fix_path_for_support_files_the_hard_way
===================================================================
--- trunk/packages/qiime/trunk/debian/patches.bak/fix_path_for_support_files_the_hard_way (rev 0)
+++ trunk/packages/qiime/trunk/debian/patches.bak/fix_path_for_support_files_the_hard_way 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,164 @@
+Get QIIME to look in the right directory for support_files.
+The default location is relative to the script which is
+in a different location depending on the python version.
+Author: Tim Booth <tbooth at ceh.ac.uk>
+
+---
+The information above should follow the Patch Tagging Guidelines, please
+checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
+are templates for supplementary fields that you might want to add:
+
+Origin: <vendor|upstream|other>, <url of original patch>
+Bug: <url in upstream bugtracker>
+Bug-Debian: http://bugs.debian.org/<bugnumber>
+Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
+Forwarded: <no|not-needed|url proving that it has been forwarded>
+Reviewed-By: <name and email of someone who approved the patch>
+Last-Update: <YYYY-MM-DD>
+
+--- a/scripts/plot_taxa_summary.py
++++ b/scripts/plot_taxa_summary.py
+@@ -219,8 +219,7 @@
+ pass
+
+ # move javascript file to javascript output directory
+- shutil.copyfile(os.path.join(qiime_dir,'qiime','support_files',\
+- 'js/overlib.js'),\
++ shutil.copyfile('/usr/lib/qiime/support_files/js/overlib.js',\
+ os.path.join(javascript_path,'overlib.js'))
+
+ #make css output directory
+@@ -231,8 +230,7 @@
+ pass
+
+ # move css file to css output directory
+- shutil.copyfile(os.path.join(qiime_dir,'qiime','support_files',\
+- 'css/qiime_style.css'),\
++ shutil.copyfile('/usr/lib/qiime/support_files/css/qiime_style.css',\
+ os.path.join(css_path,'qiime_style.css'))
+
+ # verify all parameters are valid
+--- a/scripts/make_otu_heatmap_html.py
++++ b/scripts/make_otu_heatmap_html.py
+@@ -137,7 +137,8 @@
+
+ qiime_dir=get_qiime_project_dir()
+
+- js_path=os.path.join(qiime_dir,'qiime/support_files/js')
++ #js_path=os.path.join(qiime_dir,'qiime/support_files/js')
++ js_path='/usr/lib/qiime/support_files/js'
+
+ shutil.copyfile(os.path.join(js_path,'overlib.js'), os.path.join(js_dir_path,'overlib.js'))
+ shutil.copyfile(os.path.join(js_path,'otu_count_display.js'), os.path.join(js_dir_path,'otu_count_display.js'))
+--- a/scripts/compare_3d_plots.py
++++ b/scripts/compare_3d_plots.py
+@@ -143,7 +143,8 @@
+
+ qiime_dir=get_qiime_project_dir()
+
+- jar_path=os.path.join(qiime_dir,'qiime/support_files/jar/')
++ #jar_path=os.path.join(qiime_dir,'qiime/support_files/jar/')
++ jar_path='/usr/lib/qiime/support_files/jar/'
+
+ data_dir_path = get_random_directory_name(output_dir=dir_path,
+ return_absolute_path=False)
+--- a/scripts/make_distance_histograms.py
++++ b/scripts/make_distance_histograms.py
+@@ -142,7 +142,8 @@
+ for color_info in groups_and_colors:
+ field_to_colors[color_info[0]]=color_info[1:]
+
+- qiime_dir = get_qiime_project_dir()+'/qiime/support_files/'
++ #qiime_dir = get_qiime_project_dir()+'/qiime/support_files/'
++ qiime_dir='/usr/lib/qiime/support_files/'
+
+ fields = opts.fields
+ if fields is not None:
+--- a/scripts/make_2d_plots.py
++++ b/scripts/make_2d_plots.py
+@@ -148,7 +148,8 @@
+
+ qiime_dir=get_qiime_project_dir()
+
+- js_path=os.path.join(qiime_dir,'qiime','support_files','js')
++ #js_path=os.path.join(qiime_dir,'qiime','support_files','js')
++ js_path='/usr/lib/qiime/support_files/js'
+
+ if opts.output_dir:
+ if os.path.exists(opts.output_dir):
+--- a/qiime/util.py
++++ b/qiime/util.py
+@@ -295,9 +295,7 @@
+ """Return default parameters read in from file"""
+
+ qiime_config_filepaths = []
+- qiime_project_dir = get_qiime_project_dir()
+- qiime_config_filepaths.append(\
+- qiime_project_dir + '/qiime/support_files/qiime_config')
++ qiime_config_filepaths.append('/etc/qiime/qiime_config')
+
+ qiime_config_env_filepath = getenv('QIIME_CONFIG_FP')
+ if qiime_config_env_filepath:
+@@ -1578,7 +1576,7 @@
+
+ class RExecutor(CommandLineApplication):
+ """RExecutor application controller
+- Runs R with a source script (from qiime/support_files/R)
++ Runs R with a source script (from /usr/lib/qiime/support_files/R)
+ """
+ _input_handler = '_input_as_path'
+ _command = "R"
+@@ -1588,7 +1586,7 @@
+ 'flags': '--slave'
+ }
+
+- # The name of the R script (located under qiime/support_files/R/)
++ # The name of the R script (located under /usr/lib/qiime/support_files/R/)
+ _R_script = ''
+
+ _parameters = {}
+@@ -1679,9 +1677,7 @@
+ # The methods below were taken from supervised_learning.py
+ def _get_R_script_dir(self):
+ """Returns the path to the qiime R source directory."""
+- qiime_dir = get_qiime_project_dir()
+- script_dir = join(qiime_dir,'qiime','support_files','R')
+- return script_dir
++ return '/usr/lib/qiime/support_files/R'
+
+ def _get_R_script_path(self):
+ """Returns the path to the R script to be executed."""
+--- a/qiime/supervised_learning.py
++++ b/qiime/supervised_learning.py
+@@ -39,7 +39,7 @@
+
+ class RSupervisedLearner(CommandLineApplication):
+ """R Supervised Learner application controller
+- Runs R with a source script (from qiime/support_files/R), and
++ Runs R with a source script (from /usr/lib/qiime/support_files/R), and
+ passes in an OTU table and mapping file. Causes R to run a supervised
+ classifier to predict labels from a given category from the mapping file
+ using the provided OTUs.
+@@ -231,9 +231,7 @@
+ def _get_R_script_dir(self):
+ """Returns the path to the qiime R source directory
+ """
+- qiime_dir = get_qiime_project_dir()
+- script_dir = path.join(qiime_dir,'qiime','support_files','R')
+- return script_dir
++ return '/usr/lib/qiime/support_files/R')
+
+ def _get_R_script_path(self):
+ """Returns the path to the R script to be executed
+--- a/qiime/denoiser/utils.py
++++ b/qiime/denoiser/utils.py
+@@ -35,8 +35,7 @@
+ def get_denoiser_data_dir():
+ """Return the directory of the denoiser error profiles.
+ """
+- dir = get_qiime_project_dir() + "/qiime/support_files/denoiser/Data/"
+- return dir
++ return dir "/usr/lib/qiime/support_files/denoiser/Data/"
+
+ def get_flowgram_ali_exe():
+ """Return the path to the flowgram alignment prog
Added: trunk/packages/qiime/trunk/debian/patches.bak/fix_t_test_bug
===================================================================
--- trunk/packages/qiime/trunk/debian/patches.bak/fix_t_test_bug (rev 0)
+++ trunk/packages/qiime/trunk/debian/patches.bak/fix_t_test_bug 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,565 @@
+Version of the patch found here:
+https://github.com/jrrideout/qiime/commit/f9d6f4df9b227d23adf080ac012bd1331176d50c
+Extracted by cloning the repo and doing:
+git diff-tree -M -p f9d6f4d
+Then patch was manually merged and tested by running the test case.
+Note this patch introduces a dependency on the newer python-cogent.
+Patch can be dropped for 1.6 release.
+Author: Tim Booth <tbooth at ceh.ac.uk>
+
+---
+The information above should follow the Patch Tagging Guidelines, please
+checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
+are templates for supplementary fields that you might want to add:
+
+Origin: <vendor|upstream|other>, <url of original patch>
+Bug: <url in upstream bugtracker>
+Bug-Debian: http://bugs.debian.org/<bugnumber>
+Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
+Forwarded: <no|not-needed|url proving that it has been forwarded>
+Reviewed-By: <name and email of someone who approved the patch>
+Last-Update: <YYYY-MM-DD>
+
+--- qiime-1.5.0+repack.orig/ChangeLog
++++ qiime-1.5.0+repack/ChangeLog
+@@ -1,3 +1,7 @@
++Patch backported from QIIME 1.6.0, dev branch
++==================================
++* compare_alpha_diversity.py now supports both parametric and nonparametric two sample t-tests (nonparametric is the default) with the new optional options -t/--test_type and -n/--num_permutations. Also fixed a bug that used the wrong degrees of freedom in the t-tests, yielding incorrect t statistics and p-values.
++
+ QIIME 1.5.0 (8 May 2012)
+ ==================================
+ * OTU tables are now stored on disk in the BIOM file format (see http://biom-format.org). The BIOM format webpage describes the motivation for the switch, but briefly it will support interoperability of related tools (e.g., QIIME/MG-RAST/mothur/VAMPS), and is a more efficient representation of data/metadata. The biom-format projects DenseTable and SparseTable objects are now used to represent OTU tables in memory. See the convert_biom.py script in the biom-format project for converting between 'classic' and BIOM formatted OTU tables.
+--- qiime-1.5.0+repack.orig/scripts/compare_alpha_diversity.py
++++ qiime-1.5.0+repack/scripts/compare_alpha_diversity.py
+@@ -4,7 +4,7 @@ from __future__ import division
+
+ __author__ = "William Van Treuren"
+ __copyright__ = "Copyright 2011, The QIIME project"
+-__credits__ = ["William Van Treuren, Greg Caparaso"]
++__credits__ = ["William Van Treuren", "Greg Caparaso", "Jai Ram Rideout"]
+ __license__ = "GPL"
+ __version__ = "1.5.0"
+ __maintainer__ = "William Van Treuren"
+@@ -13,80 +13,117 @@ __status__ = "Release"
+
+
+ from qiime.util import parse_command_line_parameters, make_option
+-from qiime.compare_alpha_diversity import compare_alpha_diversities,\
+- extract_rarefaction_scores_at_depth
++from qiime.compare_alpha_diversity import (compare_alpha_diversities,
++ extract_rarefaction_scores_at_depth,
++ test_types)
+
+ script_info = {}
+-script_info['brief_description'] = """This script compares alpha diversities based on a t_two_sample test"""
++script_info['brief_description'] = """This script compares alpha diversities based on a two sample t-test"""
+
+-script_info['script_description'] = """This script compares the alpha diversity of entries in a rarefaction file after they have been grouped based on some category found in the mapping file based on a t_two_sample test."""
++script_info['script_description'] = """
++This script compares the alpha diversity of entries in a rarefaction file after
++they have been grouped based on some category found in the mapping file based
++on a two sample t-test. The output file contains the
++(Category: (Subcategories): t, prob). By default the two sample t-test will be
++nonparametric (i.e. using Monte Carlo permutations to calculate the p-value),
++though the user has the option to make the test a parametric t-test.
++"""
+
+ script_info['script_usage'] = []
+-script_info['script_usage'].append(("""Explanation:\ Inputs: mapping file lines (lines of a mapping file which associates to each OTU/sample a number of characteristics, given as file path), rarefaction file lines (lines of a rarefaction file that has scores for each OTU/sample based on a certain rarefaction depth, given as a file path), depth (the depth score of the rarefaction file to use), category (the category to compare OTU/samples on), output file path (a path to the output file).""",\
+- """""",\
+- """%prog -i PD_whole_tree.txt -m map.txt -c Treatment -d 100 -o PD_d100.txt"""))
+-script_info['output_description']= \
+- """Script generates an output nested dictionary which has as a first
+- key:value pair the category passed, and a dictionary which gives the
+- t_two_sample score for every possible combination of the values
+- under that category in the mapping file, saved as a text file into
+- the directory specified by the output path."""
+
++script_info['script_usage'].append(("Comparing alpha diversities",
++"The following command takes the following input: a mapping file (which "
++"associaties each sample with a number of characteristics), alpha diversity "
++"metric (the results of collate_alpha for an alpha diverity metric, like "
++"PD_whole_tree), depth (the rarefaction depth to use for comparison), "
++"category (the category in the mapping file to determine which samples to "
++"compare to each other), and output file path (a path to the output file). A "
++"nonparametric two sample t-test is run to compare the alpha diversities "
++"using the default number of Monte Carlo permutations (999).",
++"%prog -i PD_whole_tree.txt -m mapping.txt -c Treatment -d 100 -o PD_d100.txt"))
++
++script_info['script_usage'].append(("Parametric t-test",
++"The following command runs a parametric two sample t-test using the "
++"t-distribution instead of Monte Carlo permutations.",
++"%prog -i PD_whole_tree.txt -m mapping.txt -c Treatment -d 100 -o "
++"PD_d100_parametric.txt -t parametric"))
++
++script_info['output_description']= """
++Script generates an output nested dictionary which has as a first key:value
++pair the category passed, and a dictionary which gives the t_two_sample score
++for every possible combination of the values under that category in the
++mapping file, saved as a text file into the directory specified by the output
++path.
++"""
+
+-script_info['required_options']=[\
++script_info['required_options']=[
+ make_option('-i',
+ '--alpha_diversity_filepath',
+ action='store',
+ type='existing_filepath',
+ dest='alpha_diversity_fp',
+- help='path to collated alpha diversity file (as generated by collate_alpha.py) [REQUIRED]'),\
++ help='path to collated alpha diversity file (as generated by '
++ 'collate_alpha.py) [REQUIRED]'),
+ make_option('-m',
+ '--mapping_filepath',
+ action='store',
+ type='existing_filepath',
+ dest='mapping_fp',
+- help='path to the mapping file [REQUIRED]'),\
++ help='path to the mapping file [REQUIRED]'),
+ make_option('-c',
+ '--category',
+ action='store',
+ type='string',
+ dest='category',
+- help='category for comparison [REQUIRED]'),\
++ help='category for comparison [REQUIRED]'),
+ make_option('-d',
+ '--depth',
+ action='store',
+ type='string',
+ dest='depth',
+- help='depth of rarefaction file to use [REQUIRED]'),\
++ help='depth of rarefaction file to use [REQUIRED]'),
+ make_option('-o',
+ '--output_filepath',
+ action='store',
+ type='new_filepath',
+ dest='output_fp',
+ help='output file path [REQUIRED]')]
++
++script_info['optional_options'] = [
++ make_option('-t', '--test_type', type='choice', choices=test_types,
++ help='the type of test to perform when calculating the p-values. Valid '
++ 'choices: ' + ', '.join(test_types) + '. If test_type is '
++ 'nonparametric, Monte Carlo permutations will be used to determine the '
++ 'p-value. If test_type is parametric, the num_permutations option will '
++ 'be ignored and the t-distribution will be used instead [default: '
++ '%default]', default='nonparametric'),
++ make_option('-n', '--num_permutations', type='int', default=999,
++ help='the number of permutations to perform when calculating the '
++ 'p-value. Must be greater than zero. Only applies if test_type is '
++ 'nonparametric [default: %default]')]
++
+ script_info['version'] = __version__
+
+ def main():
+ option_parser, opts, args = parse_command_line_parameters(**script_info)
++
+ rarefaction_lines = open(opts.alpha_diversity_fp, 'U')
+-
+ mapping_lines = open(opts.mapping_fp, 'U')
+ category = opts.category
+ depth = int(opts.depth)
+ output_path = opts.output_fp
+-
+-
+- result = compare_alpha_diversities(rarefaction_lines,\
+- mapping_lines,\
+- category,\
+- depth)
++
++ result = compare_alpha_diversities(rarefaction_lines, mapping_lines,
++ category, depth, opts.test_type,
++ opts.num_permutations)
+ outfile = open(output_path, 'w')
+ outfile.write(str(result))
+-
++ outfile.write('\n')
++
+ outfile.close()
+ rarefaction_lines.close()
+- mapping_lines.close()
+-
+-
++ mapping_lines.close()
++
++
+ if __name__ == "__main__":
+ main()
+--- qiime-1.5.0+repack.orig/qiime/compare_alpha_diversity.py
++++ qiime-1.5.0+repack/qiime/compare_alpha_diversity.py
+@@ -4,7 +4,7 @@ from __future__ import division
+
+ __author__ = "William Van Treuren"
+ __copyright__ = "Copyright 2011, The QIIME project"
+-__credits__ = ["William Van Treuren","Greg Caporaso"]
++__credits__ = ["William Van Treuren", "Greg Caporaso", "Jai Ram Rideout"]
+ __license__ = "GPL"
+ __version__ = "1.5.0"
+ __maintainer__ = "William Van Treuren"
+@@ -12,8 +12,11 @@ __email__ = "vantreur at colorado.edu"
+ __status__ = "Release"
+
+ from numpy import array, isnan
++from qiime.format import format_p_value_for_num_iters
+ from qiime.parse import parse_mapping_file_to_dict, parse_rarefaction
+-from cogent.maths.stats.test import t_two_sample
++from cogent.maths.stats.test import mc_t_two_sample, t_two_sample
++
++test_types = ['parametric', 'nonparametric']
+
+ def make_value_pairs_from_category(mapping_data, category):
+ """creates all pairs of unique category values from mapping data
+@@ -249,7 +252,8 @@ def convert_SampleIds_to_rarefaction_mtx
+
+
+ def compare_alpha_diversities(rarefaction_lines, mapping_lines,
+- category, depth):
++ category, depth, test_type='nonparametric',
++ num_permutations=999):
+ """compares alpha diversities
+
+ inputs:
+@@ -262,6 +266,12 @@ def compare_alpha_diversities(rarefactio
+ category - the category to be compared, is a string
+
+ depth - the depth of the rarefaction_file to use, is an integer
++
++ test_type - the type of t-test to perform, is a string. Must be either
++ 'parametric' or 'nonparametric'
++
++ num_permutations - the number of Monte Carlo permutations to use if
++ test_type is 'nonparametric', is an integer
+
+ outputs:
+ results - a nested dictionary which specifies the category as
+@@ -270,6 +280,9 @@ def compare_alpha_diversities(rarefactio
+ in the specified category
+
+ """
++ if test_type == 'nonparametric' and num_permutations < 1:
++ raise ValueError("Invalid number of permutations: %d. Must be greater "
++ "than zero." % num_permutations)
+
+ rarefaction_data = parse_rarefaction(rarefaction_lines)
+ mapping_data = parse_mapping_file_to_dict(mapping_lines)[0]
+@@ -290,15 +303,26 @@ def compare_alpha_diversities(rarefactio
+ results = {category:{}}
+
+ for pair in range(len(SampleId_pairs)):
++ # Must flatten the matrix because t_two_sample only operates on
++ # non-nested sequences (otherwise we'll get the wrong degrees of
++ # freedom).
+ i=(convert_SampleIds_to_rarefaction_mtx(SampleId_pairs[pair][0],
+- reduced_rarefaction_mtx, map_from_Id_to_col))
++ reduced_rarefaction_mtx,
++ map_from_Id_to_col)).flatten()
+
+ j=(convert_SampleIds_to_rarefaction_mtx(SampleId_pairs[pair][1],
+- reduced_rarefaction_mtx, map_from_Id_to_col))
+-
++ reduced_rarefaction_mtx,
++ map_from_Id_to_col)).flatten()
++
++ if test_type == 'parametric':
++ obs_t, p_val = t_two_sample(i,j)
++ elif test_type == 'nonparametric':
++ obs_t, _, _, p_val = mc_t_two_sample(i,j,
++ permutations=num_permutations)
++ p_val = format_p_value_for_num_iters(p_val, num_permutations)
++ else:
++ raise ValueError("Invalid test type '%s'." % test_type)
++
+ results[category][(str(value_pairs[pair][0]),
+- str(value_pairs[pair][1]))] =\
+- t_two_sample(i,j)
+-
++ str(value_pairs[pair][1]))] = obs_t, p_val
+ return results
+-
+--- qiime-1.5.0+repack.orig/tests/test_compare_alpha_diversities.py
++++ qiime-1.5.0+repack/tests/test_compare_alpha_diversities.py
+@@ -1,19 +1,16 @@
+ #!/usr/bin/env python
+ # File created on 19 May 2011
+
+-
+ from __future__ import division
+
+ __author__ = "William Van Treuren"
+ __copyright__ = "Copyright 2011, The QIIME project"
+-__credits__ = ["William Van Treuren, Greg Caporaso"]
++__credits__ = ["William Van Treuren", "Greg Caporaso", "Jai Ram Rideout"]
+ __license__ = "GPL"
+ __version__ = "1.5.0"
+ __maintainer__ = "William Van Treuren"
+ __email__ = "vantreur at colorado.edu"
+-__status__ = "Release"
+-
+-
++__status__ = "Development"
+
+ from cogent.util.unit_test import TestCase,main
+ from qiime.parse import parse_mapping_file_to_dict, parse_rarefaction
+@@ -32,13 +29,13 @@ class TopLevelTests(TestCase):
+ def setUp(self):
+ """define data for tests"""
+ self.rarefaction_file = \
+- ['\tsequences per sample\titeration\t123\t234\t345',
+- 'rare10.txt\t10\t0\t1.99181\t5.42877\t2.13996',
+- 'rare10.txt\t10\t1\t2.07163\t1.42877\t2.37055',
+- 'rare310.txt\t310\t0\t8.83115\t6.42877\t11.00725',
+- 'rare310.txt\t310\t1\t10.05242\t9.42877\t8.24474',
+- 'rare810.txt\t810\t0\t12.03067\tn/a\t11.58928',
+- 'rare910.txt\t910\t1\t12.9862\t2.42877\t11.58642']
++ ['\tsequences per sample\titeration\t123\t234\t345\t456',
++ 'rare10.txt\t10\t0\t1.99181\t5.42877\t2.13996\t0.002322',
++ 'rare10.txt\t10\t1\t2.07163\t1.42877\t2.37055\t0.01219',
++ 'rare310.txt\t310\t0\t8.83115\t6.42877\t11.00725\t0.18233',
++ 'rare310.txt\t310\t1\t10.05242\t9.42877\t8.24474\t0.99229',
++ 'rare810.txt\t810\t0\t12.03067\tn/a\t11.58928\t0.8993',
++ 'rare910.txt\t910\t1\t12.9862\t2.42877\t11.58642\t1.22563']
+
+ self.rarefaction_data = parse_rarefaction(self.rarefaction_file)
+
+@@ -48,7 +45,9 @@ class TopLevelTests(TestCase):
+ '#Comment Line',
+ '123\tAAAA\tBBBB\tHigh\t31\tM_ID_123',
+ '234\tCCCC\tDDDD\tLow\t67\tM_ID_234',
+- '345\tAAAA\tFFFF\tMed\t21\tM_ID_345']
++ '345\tAAAA\tFFFF\tMed\t21\tM_ID_345',
++ '456\tAAAA\tGGGG\tLow\t67\tM_ID_456'
++ ]
+
+ self.mapping_data = \
+ parse_mapping_file_to_dict(self.mapping_file)[0]
+@@ -59,32 +58,34 @@ class TopLevelTests(TestCase):
+ self.value_pairs_Treatment = \
+ [('CCCC', 'AAAA')]
+ self.cat_val_Dose = \
+- {'High': ['123'], 'Low': ['234'], 'Med': ['345']}
++ {'High': ['123'], 'Low': ['234', '456'], 'Med': ['345']}
+ self.cat_val_TTD = \
+- {'21': ['345'], '31': ['123'], '67': ['234']}
++ {'21': ['345'], '31': ['123'], '67': ['234', '456']}
+ self.cat_val_Treatment = \
+- {'AAAA': ['345', '123'], 'CCCC': ['234']}
++ {'AAAA': ['345', '123', '456'], 'CCCC': ['234']}
+ self.Id_pairs_Dose = \
+- [(['234'], ['345']), (['234'], ['123']), (['345'], ['123'])]
++ [(['234', '456'], ['345']), (['234', '456'], ['123']),
++ (['345'], ['123'])]
+ self.Id_pairs_TTD = \
+- [(['234'], ['345']), (['234'], ['123']), (['345'], ['123'])]
++ [(['234', '456'], ['345']), (['234', '456'], ['123']),
++ (['345'], ['123'])]
+
+ self.Id_pairs_Treatment = \
+- [(['234'], ['345', '123'])]
++ [(['234'], ['345', '123', '456'])]
+
+ self.rarefaction_cols_dict = \
+- {'123': 0, '234': 1, '345': 2}
++ {'123': 0, '234': 1, '345': 2, '456':3}
+
+ self.extracted_mtx_10 = \
+- array([[ 1.99181, 5.42877, 2.13996],
+- [ 2.07163, 1.42877, 2.37055]])
++ array([[ 1.99181, 5.42877, 2.13996, 0.002322],
++ [ 2.07163, 1.42877, 2.37055, 0.01219]])
+
+ self.extracted_mtx_310 = \
+- array([[ 8.83115, 6.42877, 11.00725],
+- [ 10.05242, 9.42877, 8.24474]])
++ array([[ 8.83115, 6.42877, 11.00725, 0.18233],
++ [ 10.05242, 9.42877, 8.24474, 0.99229]])
+
+ self.extracted_mtx_910 = \
+- array([[ 12.9862 , 2.42877, 11.58642]])
++ array([[ 12.9862 , 2.42877, 11.58642, 1.22563]])
+
+ self.sample_pair1 = \
+ (['234'], ['345', '123'])
+@@ -97,28 +98,26 @@ class TopLevelTests(TestCase):
+ array([[ 2.13996, 1.99181],
+ [ 2.37055, 2.07163]])
+
+- self.compared_alpha_diversities_TTD = \
+- {'TTD':{('21','31'):(1.8321466933860993,0.20839398129924847),
+- ('67', '21'): (0.58578495700890432, 0.61731739324369639),
+- ('67', '31'): (0.69838596448703294, 0.55721515283248324)}}
+-
++ self.compared_alpha_diversities_TTD = {'TTD': {('67', '21'):
++ (-0.27929839680103463, 0.79386220041241184), ('21', '31'):
++ (1.8321466933860993, 0.20839398129924847), ('67', '31'):
++ (-0.16318504125427058, 0.87828549279958279)}}
++
+ def test_make_value_pairs_from_category(self):
+ """check value pairs returns correct unique pairs for categories
+ """
+-
+-
++
+ self.assertEqual(
+- self.value_pairs_Dose,
+- make_value_pairs_from_category(self.mapping_data, 'Dose'))
++ make_value_pairs_from_category(self.mapping_data, 'Dose'),
++ self.value_pairs_Dose)
+
+ self.assertEqual(
+- self.value_pairs_TTD,
+- make_value_pairs_from_category(self.mapping_data, 'TTD'))
++ make_value_pairs_from_category(self.mapping_data, 'TTD'),
++ self.value_pairs_TTD)
+
+ self.assertEqual(
+- self.value_pairs_Treatment,
+- make_value_pairs_from_category(self.mapping_data,
+- 'Treatment'))
++ make_value_pairs_from_category(self.mapping_data, 'Treatment'),
++ self.value_pairs_Treatment)
+
+ self.assertRaises(
+ ValueError,
+@@ -128,59 +127,57 @@ class TopLevelTests(TestCase):
+ """check value pairs reference correct Id pairs"""
+
+ self.assertEqual(
+- self.cat_val_Dose,
+- make_category_values_Id_dict(self.mapping_data, 'Dose'))
++ make_category_values_Id_dict(self.mapping_data, 'Dose'),
++ self.cat_val_Dose)
+
+ self.assertEqual(
+- self.cat_val_TTD,
+- make_category_values_Id_dict(self.mapping_data, 'TTD'))
++ make_category_values_Id_dict(self.mapping_data, 'TTD'),
++ self.cat_val_TTD)
+
+ self.assertEqual(
+- self.cat_val_Treatment,
+- make_category_values_Id_dict(self.mapping_data,
+- 'Treatment'))
++ make_category_values_Id_dict(self.mapping_data, 'Treatment'),
++ self.cat_val_Treatment)
+
+ def test_map_category_value_pairs_to_Ids(self):
+ """check value pairs converted to correct Ids"""
+
+ self.assertEqual(
+- self.Id_pairs_Dose,
+ map_category_value_pairs_to_Ids(self.value_pairs_Dose,
+- self.cat_val_Dose))
++ self.cat_val_Dose),
++ self.Id_pairs_Dose)
+
+ self.assertEqual(
+- self.Id_pairs_TTD,
+ map_category_value_pairs_to_Ids(self.value_pairs_TTD,
+- self.cat_val_TTD))
++ self.cat_val_TTD),
++ self.Id_pairs_TTD)
+
+ self.assertEqual(
+- self.Id_pairs_Treatment,
+- map_category_value_pairs_to_Ids(
+- self.value_pairs_Treatment,
+- self.cat_val_Treatment))
++ map_category_value_pairs_to_Ids(self.value_pairs_Treatment,
++ self.cat_val_Treatment),
++ self.Id_pairs_Treatment)
+
+ def test_make_SampleIds_rarefaction_columns_dict(self):
+ """ """
+
+ self.assertEqual(
+- self.rarefaction_cols_dict,
+- make_SampleIds_rarefaction_columns_dict(self.rarefaction_data))
++ make_SampleIds_rarefaction_columns_dict(self.rarefaction_data),
++ self.rarefaction_cols_dict)
+
+ def test_extract_rarefaction_scores_at_depth(self):
+ """check correct errors raised for wrong depths and correct mtx
+ """
+
+- self.assertEqual(
+- self.extracted_mtx_10,
+- extract_rarefaction_scores_at_depth(10,self.rarefaction_data))
+-
+- self.assertEqual(
+- self.extracted_mtx_310,
+- extract_rarefaction_scores_at_depth(310,self.rarefaction_data))
+-
+- self.assertEqual(
+- self.extracted_mtx_910,
+- extract_rarefaction_scores_at_depth(910,self.rarefaction_data))
++ self.assertFloatEqual(
++ extract_rarefaction_scores_at_depth(10,self.rarefaction_data),
++ self.extracted_mtx_10)
++
++ self.assertFloatEqual(
++ extract_rarefaction_scores_at_depth(310,self.rarefaction_data),
++ self.extracted_mtx_310)
++
++ self.assertFloatEqual(
++ extract_rarefaction_scores_at_depth(910,self.rarefaction_data),
++ self.extracted_mtx_910)
+
+ self.assertRaises(
+ ValueError,
+@@ -215,13 +212,48 @@ class TopLevelTests(TestCase):
+ self.rarefaction_cols_dict),
+ self.rarefaction_mtx_for_sample_pair1_1)
+
+- def test_compare_alpha_diversity(self):
+- """test main function properly compares alpha diversities"""
++ def test_compare_alpha_diversities_parametric(self):
++ """test main function properly compares alpha divs (parametric)"""
+
+- self.assertEqual(
+- self.compared_alpha_diversities_TTD,
++ self.assertFloatEqual(
+ compare_alpha_diversities(self.rarefaction_file,
+- self.mapping_file, 'TTD', 10))
++ self.mapping_file, 'TTD', 10,
++ 'parametric'),
++ self.compared_alpha_diversities_TTD)
++
++ # Should ignore num_permutations if test_type is parametric.
++ self.assertFloatEqual(
++ compare_alpha_diversities(self.rarefaction_file,
++ self.mapping_file, 'TTD', 10,
++ 'parametric', 0),
++ self.compared_alpha_diversities_TTD)
++
++ def test_compare_alpha_diversities_nonparametric(self):
++ """test main function properly compares alpha divs (nonparametric)"""
++
++ obs = compare_alpha_diversities(self.rarefaction_file,
++ self.mapping_file, 'TTD', 10,
++ 'nonparametric')
++
++ # Since p-values are stochastic, we'll check that they are sane and
++ # that the t statistics are the same as we'd get for a parametric test.
++ for comp, (t, p_val) in obs['TTD'].items():
++ exp = self.compared_alpha_diversities_TTD['TTD'][comp]
++ self.assertFloatEqual(t, exp[0])
++ self.assertIsProb(float(p_val))
++
++ def test_compare_alpha_diversities_invalid_input(self):
++ """test main function bails on bad input"""
++
++ # Invalid test_type.
++ self.assertRaises(ValueError, compare_alpha_diversities,
++ self.rarefaction_file, self.mapping_file, 'TTD', 10,
++ 'foo')
++
++ # Invalid num_permutations.
++ self.assertRaises(ValueError, compare_alpha_diversities,
++ self.rarefaction_file, self.mapping_file, 'TTD', 10,
++ 'nonparametric', 0)
+
+
+ if __name__ == "__main__":
Added: trunk/packages/qiime/trunk/debian/patches.bak/make_qiime_accept_new_rdp_classifier
===================================================================
--- trunk/packages/qiime/trunk/debian/patches.bak/make_qiime_accept_new_rdp_classifier (rev 0)
+++ trunk/packages/qiime/trunk/debian/patches.bak/make_qiime_accept_new_rdp_classifier 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,48 @@
+This patch twists QIIME's arm to accept running a newer version
+of the RDP classifier by setting RDP_JAR_VERSION_OK, which is done
+by the QIIME wrapper.
+This is a nasty hack and hopefully the patch can be dropped for QIIME 1.6
+--- a/qiime/assign_taxonomy.py
++++ b/qiime/assign_taxonomy.py
+@@ -60,14 +60,20 @@
+ "http://qiime.org/install/install.html#rdp-install"
+ )
+
+- rdp_jarname = os.path.basename(rdp_jarpath)
+- version_match = re.search("\d\.\d", rdp_jarname)
+- if version_match is None:
+- raise RuntimeError(
+- "Unable to detect RDP Classifier version in file %s" % rdp_jarname
+- )
++ #Patch for Bio-Linux/Debian. Allow us to reassure QIIME about the version
++ #of RDP Classifier using an environment variable.
++ if os.getenv('RDP_JAR_VERSION_OK') is not None :
++ version = os.getenv('RDP_JAR_VERSION_OK')
++ else :
++ rdp_jarname = os.path.basename(rdp_jarpath)
++ version_match = re.search("\d\.\d", rdp_jarname)
++ if version_match is None:
++ raise RuntimeError(
++ "Unable to detect RDP Classifier version in file %s" % rdp_jarname
++ )
++
++ version = float(version_match.group())
+
+- version = float(version_match.group())
+ if version < 2.1:
+ raise RuntimeError(
+ "RDP Classifier does not look like version 2.2 or greater."
+--- a/scripts/assign_taxonomy.py
++++ b/scripts/assign_taxonomy.py
+@@ -258,6 +258,11 @@
+ params['training_data_properties_fp'] = opts.training_data_properties_fp
+ params['max_memory'] = "%sM" % opts.rdp_max_memory
+
++ #Record actual RDP version. This shouldn't fail as it was called once
++ #already.
++ params['real_rdp_version'] = str(validate_rdp_version())
++
++
+ elif assignment_method == 'rtax':
+ params['id_to_taxonomy_fp'] = opts.id_to_taxonomy_fp
+ params['reference_sequences_fp'] = opts.reference_seqs_fp
Added: trunk/packages/qiime/trunk/debian/patches.bak/series
===================================================================
--- trunk/packages/qiime/trunk/debian/patches.bak/series (rev 0)
+++ trunk/packages/qiime/trunk/debian/patches.bak/series 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,4 @@
+check_config_file_in_new_location.patch
+fix_binary_helper_location.patch
+make_qiime_accept_new_rdp_classifier
+fix_path_for_support_files
Added: trunk/packages/qiime/trunk/debian/scripts.bak/qiime
===================================================================
--- trunk/packages/qiime/trunk/debian/scripts.bak/qiime (rev 0)
+++ trunk/packages/qiime/trunk/debian/scripts.bak/qiime 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,53 @@
+#!/bin/sh
+
+# Set up a Qiime working environment. This should either run the Qiime command directly
+# or else drop the user to a shell where Qiime is ready to run.
+# For now, if $SHELL is zsh use that, otherwise run bash.
+
+if [ "$*" = "" ] ; then
+ #Run a shell
+ if [ `basename "$SHELL"` = "zsh" ] ; then
+ export ZOLDDOTDIR=${ZSHDOTDIR:-~}
+ export ZDOTDIR=/usr/lib/qiime/shell
+ QIIMESHELL="$SHELL"
+ QSNAME="ZSH ($SHELL)"
+ elif [ `basename "$SHELL"` = "bash" ] ; then
+ #Set bash dot directory.
+ QIIMESHELL="$SHELL --rcfile /usr/lib/qiime/shell/.bashrc"
+ QSNAME="BASH ($SHELL)"
+ else
+ if which bash > /dev/null ; then
+ QIIMESHELL="bash --rcfile /usr/lib/qiime/shell/.bashrc"
+ QSNAME="BASH"
+ else
+ #This should never happen due to package dependencies.
+ echo "To start an interactive Qiime shell, you need to have 'bash' available and"
+ echo "in your path."
+ exit 1
+ fi
+ fi
+
+#Determine Qiime version:
+QIIME_VERSION=`/usr/lib/qiime/bin/print_qiime_config.py --version 2>/dev/null | awk '{print $NF}'`
+QIIME_VERSION=${QIIME_VERSION:-UNKNOWN}
+
+echo """
+Setting up $QSNAME environment to run QIIME commands.
+
+You have QIIME version $QIIME_VERSION.
+Type 'help' for more info, 'exit' to return to regular shell.
+"""
+
+ eval exec $QIIMESHELL
+
+else
+ #Just run the command
+
+ # Set environment
+ . /usr/lib/qiime/shell/qiime_environment
+
+ cmd=`basename "$1" .py`.py
+ shift
+
+ exec "/usr/lib/qiime/bin/$cmd" "$@"
+fi
Added: trunk/packages/qiime/trunk/debian/scripts.bak/qiime_config
===================================================================
--- trunk/packages/qiime/trunk/debian/scripts.bak/qiime_config (rev 0)
+++ trunk/packages/qiime/trunk/debian/scripts.bak/qiime_config 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,17 @@
+# qiime_config
+# WARNING: DO NOT EDIT OR DELETE Qiime/qiime_config
+# To overwrite defaults, copy this file to $HOME/.qiime_config or a full path
+# specified by $QIIME_CONFIG_FP and edit that copy of the file.
+
+cluster_jobs_fp
+python_exe_fp python
+working_dir .
+blastmat_dir /usr/share/ncbi/data
+blastall_fp blastall
+pynast_template_alignment_fp
+pynast_template_alignment_blastdb
+template_alignment_lanemask_fp
+jobs_to_start 1
+seconds_to_sleep 60
+qiime_scripts_dir /usr/lib/qiime/bin/
+temp_dir /tmp
Added: trunk/packages/qiime/trunk/debian/scripts.bak/shell/.bashrc
===================================================================
--- trunk/packages/qiime/trunk/debian/scripts.bak/shell/.bashrc (rev 0)
+++ trunk/packages/qiime/trunk/debian/scripts.bak/shell/.bashrc 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,12 @@
+# Startup script for BASH with Qiime environment.
+# Source the user's default environent.
+test -e "/etc/bash.bashrc" && source "/etc/bash.bashrc"
+test -e "~/.bashrc" && source "~/.bashrc"
+
+help()
+{
+ cat "$QIIME_HELP_TEXT"
+}
+
+source /usr/lib/qiime/shell/qiime_environment
+PS1="$PS1 qiime > "
Added: trunk/packages/qiime/trunk/debian/scripts.bak/shell/.zshrc
===================================================================
--- trunk/packages/qiime/trunk/debian/scripts.bak/shell/.zshrc (rev 0)
+++ trunk/packages/qiime/trunk/debian/scripts.bak/shell/.zshrc 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,14 @@
+# Startup script for ZSH with Qiime environment.
+if [ -e "$ZOLDDOTDIR/.zshrc" ] ; then
+ source "$ZOLDDOTDIR/.zshrc"
+ unset ZOLDDOTDIR
+fi
+
+source /usr/lib/qiime/shell/qiime_environment
+
+help()
+{
+ cat "$QIIME_HELP_TEXT"
+}
+
+PROMPT="$PROMPT qiime > "
Added: trunk/packages/qiime/trunk/debian/scripts.bak/shell/qiime_environment
===================================================================
--- trunk/packages/qiime/trunk/debian/scripts.bak/shell/qiime_environment (rev 0)
+++ trunk/packages/qiime/trunk/debian/scripts.bak/shell/qiime_environment 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,31 @@
+#In the /usr/lib/qiime/shell directory are .zshrc and .bashrc files to set up the environment
+#needed for running Qiime. There may be a less hacky way of doing this but it works for now.
+
+# Qiime basic environment. Note that sourcing this file multiple times is not idempotent
+# and should be avoided!
+# This file needs to be readable by /bin/sh and zsh so no bash-isms allowed.
+
+export PYTHONPATH=$PYTHONPATH/:/usr/share/pyshared/qiime
+export PATH="$PATH:/usr/lib/qiime/bin:/usr/share/ampliconnoise/Scripts:/usr/lib/ChimeraSlayer"
+export QIIME_HELP_TEXT=/usr/lib/qiime/shell/qiime_help
+export QIIME_CONFIG_FP=${QIIME_CONFIG_FP:-/etc/qiime/qiime_config}
+export BLASTMAT=${BLASTMAT:-/usr/share/ncbi/data}
+
+# This was previously set in bio-linux-rdp-classifier but can now live here
+# as the rdp-classifier package has been normalised.
+export RDP_JAR_PATH=${RDP_JAR_PATH:-/usr/share/rdp-classifier/rdp_classifier.jar}
+#RDP_classifier is very bad at admitting what version it is, so ask DPKG:
+export RDP_JAR_VERSION_OK=`dpkg-query -f '${Version}\n' -W rdp-classifier | sed 's/[~+-].*//'`
+
+# Mike Cox reports these are wanted for Ampliconnoise
+export PYRO_LOOKUP_FILE=${PYRO_LOOKUP_FILE:-/usr/share/ampliconnoise/Data/LookUp_E123.dat}
+export SEQ_LOOKUP_FILE=${SEQ_LOOKUP_FILE:-/usr/share/ampliconnoise/Data/Tran.dat}
+
+# Add aliases so that the biom-format tools can be called as documented in QIIME
+alias add_metadata.py=add_biom_metadata
+alias test_biom_validator.py=test_biom_validator
+alias biom_validator.py=biom_validator
+alias subset_biom.py=subset_biom
+alias convert_biom.py=convert_biom
+alias print_biom_python_config.py=print_biom_python_config
+alias print_biom_table_summary.py=print_biom_table_summary
Added: trunk/packages/qiime/trunk/debian/scripts.bak/shell/qiime_help
===================================================================
--- trunk/packages/qiime/trunk/debian/scripts.bak/shell/qiime_help (rev 0)
+++ trunk/packages/qiime/trunk/debian/scripts.bak/shell/qiime_help 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,47 @@
+This is a proto-manpage for Qiime on Debian/Bio-Linux.
+Some of this info alternatively belongs in README.Debian.
+
+INVOCATION:
+
+ To run a Qiime command such as check_id_map.py:
+
+ % qiime check_id_map [...]
+
+ or just type 'qiime' to get a shell environment where all Qiime commands are available, ie:
+
+ % qiime
+ % qiime > check_id_map.py [...]
+
+PARAMETERS FILE:
+
+ For certain qiime commands, you need to indicate where your qiime parameters file is. You
+ should make a copy of the default version at /usr/share/doc/qiime/qiime_parameters.txt and
+ edit it to suit your needs. A key thing to edit is the location of your greengenes
+ database and lanemask files.
+
+ You either need to have your edited copy of your qiime parameter file in your working
+ directory, or you need to give the path to the file using the -p parameter in the relevant
+ qiime commands.
+
+GREENGENES DATA:
+
+ Make sure that you have copies of the greengenes core set data file (fasta) and the
+ greengenes alignment lanemask file installed. These do NOT come with the bio-linux-qiime
+ package. You must edit your custom parameter file in your working directory to give the
+ full path to these files.
+
+QIIME CONFIGURATION:
+
+ Qiime reads configuration information from the file specified by QIIME_CONFIG_FP.
+ Your QIIME_CONFIG_FP is set to /etc/qiime/qiime_config. It is unlikely you will need to
+ change the settings in this file.
+
+UCLUST:
+
+ You may need to install UClust manually to use some Qiime functions.
+ For more info, try running 'uclust' at the qiime prompt.
+
+
+For more information about Qiime, please refer to the Qiime documentation at:
+
+ http://qiime.sourceforge.net/
Added: trunk/packages/qiime/trunk/debian/scripts.bak/uclust
===================================================================
--- trunk/packages/qiime/trunk/debian/scripts.bak/uclust (rev 0)
+++ trunk/packages/qiime/trunk/debian/scripts.bak/uclust 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1,32 @@
+#!/bin/sh
+#
+# Added by Tim Booth <tbooth at ceh.ac.uk>
+# Qiime wants very much to use the UClust binary, but this is not free software.
+# However, it is available right now free-of-charge if:
+# a) You are an academic user and only want the 32-bit version.
+# b) You promise to use the UClust application only as part of Qiime.
+#
+# My plan is to put the no-cost UClust into bio-linux-qiime. If someone
+# installs just the reglar qiime package they need to know what to do...
+
+# See if uclust.real is available.
+if which uclust.real >/dev/null ; then
+ exec uclust.real "$@"
+fi
+
+if [ `uname -m` = x86_64 ] ; then
+ bits='64-bit'
+else
+ bits='32-bit'
+fi
+
+echo """\r\
+UClust is not freely redistributable and is thus not included in the default Qiime package.
+
+To use this feature, please go to:
+ http://www.drive5.com/uclust/downloads1_2_22q.html
+
+Download the $bits binary, then:
+ sudo cp uclustq1.2.22_* /usr/local/bin/uclust
+ sudo chmod a+x /usr/local/bin/uclust
+"""
Added: trunk/packages/qiime/trunk/debian/source.bak/format
===================================================================
--- trunk/packages/qiime/trunk/debian/source.bak/format (rev 0)
+++ trunk/packages/qiime/trunk/debian/source.bak/format 2013-06-10 17:23:58 UTC (rev 13904)
@@ -0,0 +1 @@
+3.0 (quilt)
More information about the debian-med-commit
mailing list