diff options
author | Muriithi Frederick Muriuki | 2021-08-30 07:00:38 +0300 |
---|---|---|
committer | Muriithi Frederick Muriuki | 2021-08-30 07:00:38 +0300 |
commit | 983acfdfc523677b4d7501287a000b7fd52a2c39 (patch) | |
tree | 92547cd368fd0f024d4aedf92b1c3dc62417e65d /gn3/computations/heatmap.py | |
parent | c045122908d36bba4ca197f3f67e89d80958f38f (diff) | |
download | genenetwork3-983acfdfc523677b4d7501287a000b7fd52a2c39.tar.gz |
Implement module for interfacing with rust-qtlreaper
Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* gn3/computations/heatmap.py: move `generate_traits_file` function to new
module
* gn3/computations/qtlreaper.py: new module to interface with the
`rust-qtlreaper` utility.
* gn3/settings.py: Provide setting for the path to the `rust-qtlreaper`
utility
* qtlfilesexport.py: Move `random_string` function to new module. Update to
use functions in new module.
Provide a module with functions to be used to interface with
`rust-qtlreaper`. This module essentially contains all the functions that
are needed to build the files needed for, and to run the qtlreaper utility.
Diffstat (limited to 'gn3/computations/heatmap.py')
-rw-r--r-- | gn3/computations/heatmap.py | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/gn3/computations/heatmap.py b/gn3/computations/heatmap.py index 3e96ed2..dcd64b1 100644 --- a/gn3/computations/heatmap.py +++ b/gn3/computations/heatmap.py @@ -230,11 +230,3 @@ def retrieve_strains_and_values(orders, strainlist, traits_data_list): values = [] return rets - -def generate_traits_file(strains, trait_values, traits_filename): - header = "Traits\t{}\n".format("\t".join(strains)) - data = [header] + [ - "T{}\t{}\n".format(i+1, "\t".join([str(i) for i in t])) - for i,t in enumerate(trait_values)] - with open(traits_filename, "w") as outfile: - outfile.writelines(data) |