Skip to content

Commit

Permalink
Merge pull request #252 from bacpop/path-fix
Browse files Browse the repository at this point in the history
Path fix for distance plot, update docs with new DB page
  • Loading branch information
johnlees committed Jan 18, 2023
2 parents 9b6cad3 + de05c8d commit ed2b14f
Show file tree
Hide file tree
Showing 9 changed files with 20 additions and 127 deletions.
7 changes: 3 additions & 4 deletions PopPUNK/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,7 @@ def main():
if args.max_search_depth is not None and args.max_search_depth < max(rank_list):
sys.stderr.write("The maximum search depth must be greater than the highest lineage rank\n")
sys.exit(1)

if args.create_db == False:
# Check and set required parameters for other modes
if args.ref_db is None:
Expand Down Expand Up @@ -363,8 +363,7 @@ def main():
# Plot results
if not args.no_plot:
plot_scatter(distMat,
os.path.join(os.path.dirname(args.output),
os.path.basename(args.output) + "_distanceDistribution"),
f"{args.output}/{os.path.basename(args.output)}_distanceDistribution",
args.output + " distances")

#******************************#
Expand Down Expand Up @@ -600,7 +599,7 @@ def main():
prefix = output,
suffix = '_rank_' + str(rank) + '_graph',
use_gpu = args.gpu_graph)

# Identify clusters from output
lineage_clusters[rank] = \
printClusters(indivNetworks[rank],
Expand Down
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,10 @@
[![PyPI version](https://badge.fury.io/py/poppunk.svg)](https://badge.fury.io/py/poppunk)
<!-- badges: end -->

See our website: <https://www.poppunk.net>

## Description

See the [documentation](http://poppunk.readthedocs.io/en/latest/) and the
[paper](https://doi.org/10.1101/gr.241455.118).
See the [documentation](http://poppunk.readthedocs.io/en/latest/) the
[paper](https://doi.org/10.1101/gr.241455.118), and [databases](https://www.bacpop.org/poppunk/).

If you find PopPUNK useful, please cite us:

Expand All @@ -26,6 +24,11 @@ suggested methods paragraph.

## News

### 2023-01-18

We will retire the PopPUNK website. Databases have been expanded, and can be
found here: https://www.bacpop.org/poppunk/.

### 2022-08-04
The change in scikit-learn's API in v1.0.0 and above mean that HDBSCAN models
fitted with `sklearn <=v0.24` will give an error when loaded. If you run into this,
Expand Down
4 changes: 2 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,9 @@
# built documents.
#
# The short X.Y version.
version = '2.5.0'
version = '2.6.1'
# The full version, including alpha/beta/rc tags.
release = '2.5.0'
release = '2.6.1'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
5 changes: 2 additions & 3 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ in the `paper <https://doi.org/10.1101/gr.241455.118>`_.
visualisation.rst
mst.rst
subclustering.rst
online.rst
gpu.rst
troubleshooting.rst
scripts.rst
Expand Down Expand Up @@ -74,7 +73,7 @@ The advantages of PopPUNK are broadly that:
`phandango <http://jameshadfield.github.io/phandango/>`_.
- Everything is available within a single python executable.

Citation:
Citation
---------
If you find PopPUNK useful, please cite as:

Expand All @@ -84,7 +83,7 @@ doi:`10.1101/gr.241455.118 <https://dx.doi.org/10.1101/gr.241455.118>`__

See :doc:`citing` for more details.

Index:
Index
------

* :ref:`genindex`
Expand Down
2 changes: 1 addition & 1 deletion docs/model_distribution.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ If you have fitted a model yourself, you may be interested in distributing it so
others can use it for your species. This will give consistent cluster names across datasets,
mean the high-quality tested fit can be reused, and speeds up future analysis.

Please contact us at poppunk@poppunk.net. We would be happy to add your sketches and
Please contact us at poppunk@bacpop.org. We would be happy to add your sketches and
fitted model to our other `databases <https://poppunk.net/pages/databases.html>`__.

Database contents
Expand Down
2 changes: 1 addition & 1 deletion docs/model_fitting.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Fitting new models (``--fit-model``)
:trim:

If you cannot find an existing model for your species in the
`list <https://poppunk.net/pages/databases.html>`__ you will want to fit your own.
`list <https://www.bacpop.org/poppunk/>`__ you will want to fit your own.
This process is flexible, and there are five different models you can use depending
on the population structure of your dataset.

Expand Down
104 changes: 0 additions & 104 deletions docs/online.rst

This file was deleted.

8 changes: 2 additions & 6 deletions docs/overview.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ are the current minimum supported versions.

Use query assignment mode
^^^^^^^^^^^^^^^^^^^^^^^^^
If a database is available for your species (see https://poppunk.net/pages/databases.html)
If a database is available for your species (see https://www.bacpop.org/poppunk/)
we would strongly recommend downloading it to use to cluster your genomes. This
has many advantages:

Expand Down Expand Up @@ -65,14 +65,10 @@ See :doc:`visualisation` for details on options.
Use an online interface
-----------------------
If available, you may want to use one of the browser-based interfaces to
PopPUNK. These include `PopPUNK-web <https://web.poppunk.net/>`__ and
PopPUNK. These include `beebop <https://beebop.dide.ic.ac.uk/>`__ and
`pathogen.watch <https://pathogen.watch/genomes/all?genusId=1301&speciesId=1313>`__
(*S. pneumoniae* only).

.. warning::
PopPUNK-web is temporarily down while we work on an updated and better supported
version.

Using these interfaces requires nothing to be installed or set up, doesn't require any
genome data to be shared with us, and will return interactive visualisations. If your
species isn't available, or you have large batches of genomes to cluster you will
Expand Down
4 changes: 2 additions & 2 deletions docs/query_assignment.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ Query assignment (``poppunk_assign``)
This is the recommended mode to use PopPUNK, as long as a database is available for
your species. If there is no database available, you can fit your own (:doc:`model_fitting`).

Briefly, `download your reference database <https://poppunk.net/pages/databases.html>`__ and run::
Briefly, `download your reference database <https://www.bacpop.org/poppunk/>`__ and run::

poppunk_assign --db database --query qfile.txt \
--output poppunk_clusters --threads 8

Downloading a database
----------------------
Current PopPUNK databases can be found here: https://poppunk.net/pages/databases.html
Current PopPUNK databases can be found here: https://www.bacpop.org/poppunk/

We refer to sequences in the database as references, and those being added
as queries. The clusters assigned by PopPUNK are variable-length-k-mer clusters (VLKCs).
Expand Down

0 comments on commit ed2b14f

Please sign in to comment.