-
Notifications
You must be signed in to change notification settings - Fork 80
Adding qiime map file #678
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
Merged
ElDeveloper
merged 13 commits into
qiita-spots:master
from
antgonza:adding-qiime-map-file
Nov 24, 2014
Merged
Changes from 1 commit
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
9340a99
Merge branch 'master' of https://github.com/biocore/qiita into adding…
antgonza daac1e3
wip: adding create_qiime_map
antgonza 49c4092
Merge branch 'master' of https://github.com/biocore/qiita into adding…
antgonza 283e4bf
Merge branch 'issue-676' of https://github.com/josenavas/qiita into a…
antgonza a5247bb
adding qiime mapping file
antgonza e52e393
fixing flake8
antgonza 5d964c4
fixing errors
antgonza 0a6e70d
fixing errors due to table insert
antgonza c07967b
fix flake8, again
antgonza 4dae65c
adding test for create_qiime_map
antgonza 8f3f9dd
Merge branch 'master' of https://github.com/biocore/qiita into adding…
antgonza 010332b
addressing @ElDeveloper commenets
antgonza e2e0a05
addressing @josenavas comments
antgonza 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
adding test for create_qiime_map
- Loading branch information
commit 4dae65cd5b573884e2245be27e06d75b4de0e738
There are no files selected for viewing
This file contains hidden or 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 |
---|---|---|
|
@@ -1648,6 +1648,11 @@ def create_qiime_map(self, prep_template_fp): | |
The filepath of the prep template we want to generate the qiime | ||
mapping file | ||
|
||
Returns | ||
------- | ||
filepath : str | ||
The filepath of the created qiime file | ||
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. file ➡️ mapping file |
||
|
||
Raises | ||
------ | ||
QiitaDBColumnError | ||
|
@@ -1727,15 +1732,17 @@ def create_qiime_map(self, prep_template_fp): | |
|
||
# figuring out the filepath for the qiime map file | ||
_id, fp = get_mountpoint('templates')[0] | ||
mapping_fp = join(fp, '%d_prep_%d_qiime_%s.txt' % (self.study_id, | ||
self.id, strftime("%Y%m%d-%H%M%S"))) | ||
filepath = join(fp, '%d_prep_%d_qiime_%s.txt' % (self.study_id, | ||
self.id, strftime("%Y%m%d-%H%M%S"))) | ||
|
||
# Save the mapping file | ||
mapping.to_csv(mapping_fp, index_label='#SampleID', na_rep='unknown', | ||
mapping.to_csv(filepath, index_label='#SampleID', na_rep='unknown', | ||
sep='\t') | ||
|
||
# adding the fp to the object | ||
self.add_filepath(mapping_fp) | ||
self.add_filepath(filepath) | ||
|
||
return filepath | ||
|
||
|
||
def load_template_to_dataframe(fn): | ||
|
Oops, something went wrong.
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.
Can you revise this sentence?