Skip to content

Commit

Permalink
ENH: adds citations (#177)
Browse files Browse the repository at this point in the history
  • Loading branch information
ebolyen authored and gregcaporaso committed Apr 18, 2018
1 parent 62b564a commit fdf4f0e
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 5 deletions.
20 changes: 20 additions & 0 deletions q2_types/citations.bib
@@ -0,0 +1,20 @@
@article{mcdonald2012biological,
title={The Biological Observation Matrix (BIOM) format or: how I learned to stop worrying and love the ome-ome},
author={McDonald, Daniel and Clemente, Jose C and Kuczynski, Justin and Rideout, Jai Ram and Stombaugh, Jesse and Wendel, Doug and Wilke, Andreas and Huse, Susan and Hufnagle, John and Meyer, Folker and Knight, Rob and Caporaso, J Gregory},
journal={GigaScience},
volume={1},
number={1},
pages={7},
year={2012},
publisher={BioMed Central},
doi={10.1186/2047-217X-1-7}
}

@InProceedings{ mckinney-proc-scipy-2010,
author = { Wes McKinney },
title = { Data Structures for Statistical Computing in Python },
booktitle = { Proceedings of the 9th Python in Science Conference },
pages = { 51 -- 56 },
year = { 2010 },
editor = { St{\'e}fan van der Walt and Jarrod Millman }
}
9 changes: 5 additions & 4 deletions q2_types/feature_table/_format.py
Expand Up @@ -7,10 +7,11 @@
# ----------------------------------------------------------------------------
import ijson
import h5py
import biom

import qiime2.plugin.model as model

from ..plugin_setup import plugin
from ..plugin_setup import plugin, citations


class BIOMV100Format(model.TextFileFormat):
Expand Down Expand Up @@ -91,6 +92,6 @@ def sniff(self):
'feature-table.biom',
BIOMV210Format)

plugin.register_formats(
BIOMV100Format, BIOMV210Format, BIOMV100DirFmt, BIOMV210DirFmt
)
plugin.register_views(BIOMV100Format, BIOMV210Format, BIOMV100DirFmt,
BIOMV210DirFmt, biom.Table,
citations=[citations['mcdonald2012biological']])
6 changes: 5 additions & 1 deletion q2_types/plugin_setup.py
Expand Up @@ -8,12 +8,13 @@

import importlib

import pandas as pd
import qiime2.plugin
import qiime2.sdk

from q2_types import __version__


citations = qiime2.plugin.Citations.load('citations.bib', package='q2_types')
plugin = qiime2.plugin.Plugin(
name='types',
version=__version__,
Expand All @@ -24,6 +25,9 @@
short_description='Plugin defining types for microbiome analysis.'
)

plugin.register_views(pd.Series, pd.DataFrame,
citations=[citations['mckinney-proc-scipy-2010']])

importlib.import_module('q2_types.feature_table')
importlib.import_module('q2_types.distance_matrix')
importlib.import_module('q2_types.tree')
Expand Down
1 change: 1 addition & 0 deletions setup.py
Expand Up @@ -25,6 +25,7 @@
['q2-types=q2_types.plugin_setup:plugin']
},
package_data={
'q2_types': ['citations.bib'],
'q2_types.tests': ['data/*'],
'q2_types.distance_matrix.tests': ['data/*'],
'q2_types.feature_data.tests': ['data/*', 'data/taxonomy/*'],
Expand Down

0 comments on commit fdf4f0e

Please sign in to comment.