-
Notifications
You must be signed in to change notification settings - Fork 25
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
Changes to wrapper to integrate with Bibiserv #62
Open
foobarx
wants to merge
52
commits into
aweimann:master
Choose a base branch
from
foobarx:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 9 commits
Commits
Show all changes
52 commits
Select commit
Hold shift + click to select a range
af37b63
Update traitar_from_archive.py
foobarx 7938edc
Update traitar_from_archive.py
foobarx 672db82
Update traitar_from_archive
foobarx a9a9b8a
Update traitar_from_archive.py
foobarx 50577c1
Update hmmer2filtered_best.py
foobarx 762e9e5
Update traitar_from_archive.py
foobarx d98f808
Update traitar_from_archive.py
foobarx aef82e1
Update traitar_from_archive.py
foobarx 3e22f3e
Update traitar_from_archive.py
foobarx d3e6c2c
Update traitar.py
foobarx a62ddc9
Update hmm2gff.py
foobarx 3adb0c6
Update hmm2gff.py
foobarx 3e89594
Update traitar_from_archive.py
foobarx 66f9cb4
Update traitar_from_archive.py
foobarx 570b0e9
Update traitar_from_archive
foobarx c912740
Update traitar_from_archive.py
foobarx 6bc5cf0
Update traitar_from_archive.py
foobarx 16bba58
Update traitar_from_archive.py
foobarx aa0f57c
Update hmm2gff.py
foobarx 32feba0
Update traitar_from_archive.py
foobarx d14774d
Update traitar_from_archive.py
foobarx 7889c1c
Update traitar_from_archive.py
foobarx 0da17a7
Update traitar_from_archive.py
foobarx 9de4633
Update traitar_from_archive
foobarx 5342e89
Update traitar_from_archive.py
foobarx a3342a5
Update traitar_from_archive.py
foobarx e25d8ad
Update traitar_from_archive.py
foobarx cf1ec36
Create sample.html
foobarx 5d21ce8
Update sample.html
foobarx 2b79d38
Update traitar_from_archive.py
foobarx c4a2cea
Update traitar_from_archive
foobarx 40ffc2f
Update traitar_from_archive.py
foobarx 1fb8045
Update traitar_from_archive.py
foobarx cca8e3a
Update traitar_from_archive
foobarx 632179e
Update traitar_from_archive
foobarx 1582fc6
Update traitar_from_archive.py
foobarx fb46973
Update traitar_from_archive.py
foobarx c6b2dd7
Update traitar_from_archive.py
foobarx 872502c
Update traitar_from_archive.py
foobarx af9ae87
Update traitar_from_archive.py
foobarx 940d143
Update traitar_from_archive.py
foobarx 61b3fa5
Update traitar_from_archive.py
foobarx ecd6c75
Update traitar_from_archive.py
foobarx e99511e
Update sample.html
foobarx 5b3f682
Update sample.html
foobarx f94d4ba
Add files via upload
foobarx 8115d56
Update traitar_from_archive.py
foobarx 1547453
Update sample.html
foobarx 9c1f643
Update sample.html
foobarx 81c2e0d
Fix divegent branch
foobarx b43abc1
Merge branch 'aweimann-master'
foobarx 18f96c3
Post merge changes
foobarx File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,6 +4,8 @@ | |
import re | ||
import os | ||
from .traitar import phenolyze | ||
from shutil import copyfile | ||
|
||
|
||
def get_sample_names(namelist): | ||
"""parse sample names""" | ||
|
@@ -47,10 +49,12 @@ def read_archive(input_archive, archive_type, mode, sample2cat, input_dir): | |
|
||
#create sample table | ||
if sample2cat is not None: | ||
sample_cat = pd.read_cvs(sample2cat, index_col = 0, sep = "\t") | ||
sample_cat = pd.read_csv(sample2cat, index_col = 0, sep = "\t") | ||
#replace index with cleaned file names | ||
sample_cat.index.rename(str, dict([(tf, sfn) for sfn, tf in zip(sample_file_names, namelist)])) | ||
sample_table = pd.DataFrame([sample_file_names, sample_cat.loc[sample_file_names,]]) | ||
sample_table = pd.DataFrame(sample_file_names) | ||
categories = pd.Series(sample_cat.loc[sample_file_names, ]['category'].tolist()) | ||
sample_table['category'] = categories | ||
sample_table.columns = ["sample_file_name", "category"] | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. thanks for the changes; I think I haven't really properly tested this one! |
||
else: | ||
sample_table = pd.DataFrame(sample_file_names) | ||
|
@@ -68,3 +72,6 @@ def call_traitar(args): | |
#compress output | ||
with tarfile.open(args.out_archive, "w:gz") as tar: | ||
tar.add(args.output_dir, arcname=os.path.basename(args.output_dir)) | ||
|
||
out_image = args.out_archive.replace('.FILE', '2.FILE') | ||
copyfile(args.output_dir+"/phenotype_prediction/heatmap_combined.pdf", out_image) |
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why would you do this?