logo Netzschleuder network catalog, repository, and centrifuge

History of yeast_biogrid_2007

The changes to the source code of this entry in the repository, newest first, each with the differences it made to the entry's files. They are also listed on GitLab.

[entries] New entry: yeast_biogrid_2007 by Tiago de Paula Peixoto 29db713
diff --git a/entries/yeast_biogrid_2007/__init__.py b/entries/yeast_biogrid_2007/__init__.py
new file mode 100644
index 0000000..59685ee
--- /dev/null
+++ b/entries/yeast_biogrid_2007/__init__.py
@@ -0,0 +1,58 @@
+#! /usr/bin/env python
+# -*- coding: utf-8 -*-
+#
+# Copyright (C) 2020-2026 Tiago de Paula Peixoto <tiago@skewed.de>
+#
+# This program is free software: you can redistribute it and/or modify it under
+# the terms of the GNU Affero General Public License as published by the Free
+# Software Foundation, either version 3 of the License, or (at your option) any
+# later version.
+#
+# This program is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+# FOR A PARTICULAR PURPOSE.  See the GNU Affero General Public License for more
+# details.
+#
+# You should have received a copy of the GNU Affero General Public License along
+# with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+
+from .. import *
+
+
+title = "Yeast protein interactions (BioGRID, 2007)"
+description = """The network of protein-protein interactions in the yeast Saccharomyces cerevisiae, as recorded in the January 2007 version of the BioGRID database, a general repository of biological interaction data aggregating published experimental results from many laboratories on the affinity of protein pairs to interact. The network was assembled by X. Jiang, N. Nariai, M. Steffen, S. Kasif and E. D. Kolaczyk for the study of protein function prediction, and distributed by E. D. Kolaczyk on the data page of the book "Statistical Analysis of Network Data" (no longer online), from which this version was obtained via the Internet Archive.
+
+An undirected edge connects two proteins with a recorded physical interaction.
+
+The network has the following properties:
+
+- Nodes: `name`, the systematic name of the yeast gene encoding the protein (ORF name)."""
+tags = ['Biological', 'Protein interactions', 'Unweighted']
+url = 'https://web.archive.org/web/20090821190310/http://math.bu.edu/people/kolaczyk/datasets.html'
+citation = [('X. Jiang, N. Nariai, M. Steffen, S. Kasif, E. D. Kolaczyk, "Integration of relational and hierarchical network information for protein function prediction." BMC Bioinformatics 9, 350 (2008)', 'https://doi.org/10.1186/1471-2105-9-350')]
+icon_hash = '59233d1d62da63251188ee8d'
+upstream_license = None
+upstream_prefix = 'https://web.archive.org/web/20100817183459id_/http://math.bu.edu/people/kolaczyk/datasets'
+files = [('ppi.zip:ppi.txt', None, None)]
+
+def fetch_upstream(force=False):
+    # The Wayback Machine refuses connections or fails when rate-limited, so
+    # retry with increasing pauses (files already fetched are skipped)
+    return retry_download(fetch_upstream_files, __name__.split(".")[-1],
+                          upstream_prefix, files, force)
+
+@cache_network()
+@coerce_props()
+@annotate()
+def parse(alts=None):
+    global files
+    name = __name__.split(".")[-1]
+    for fnames, alt, fmt in files:
+        if alts is not None and alt not in alts:
+            continue
+        with open_upstream_file(name, fnames, "r") as f:
+            g = Graph(directed=False)
+            g.vp.name = g.add_edge_list((line.split() for line in f if line.strip()),
+                                        hashed=True, hash_type="string")
+        yield alt, g