Skip to content

Commit

Permalink
Merge pull request #18 from jason-neal/badges
Browse files Browse the repository at this point in the history
Update display of badges in readme and in docs. 
Update travis.yml for codeclimate.
  • Loading branch information
jason-neal committed Apr 25, 2017
2 parents e179dd3 + cd8904f commit e5d9694
Show file tree
Hide file tree
Showing 3 changed files with 71 additions and 25 deletions.
19 changes: 5 additions & 14 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,9 @@ python:
- "2.7"
- "3.4"
- "3.5"
#- "3.5-dev" # 3.5 development branch
#- "nightly" # currently points to 3.6-dev
# command to install dependencies
- "3.6"

#install: "pip install -r requirements.txt"
# command to install dependencies
# Setup anaconda
before_install:
# http://conda.pydata.org/docs/travis.html
Expand All @@ -24,27 +22,20 @@ before_install:
- conda update -q conda
- conda info -a
install:
#- conda install --yes python=$TRAVIS_PYTHON_VERSION numpy scipy matplotlib #nose atlas dateutil pandas statsmodels
# Coverage packages are on my binstar channel
#- conda install --yes -c dan_blanchard python-coveralls nose-cov
- conda create -q -n test-environment python=$TRAVIS_PYTHON_VERSION numpy scipy astropy
- source activate test-environment
- pip install pyastronomy
- python setup.py install

- pip install pytest-cov python-coveralls
- pip install pytest-cov python-coveralls codeclimate-test-reporter
- pip install -r requirements.txt
# install:
# - pip install numpy
# - pip install tox
# - pip install matplotlib
# - pip install hypothesis

# command to run tests
script:
# - py.test -cov coveralls --cov-report term-missing
# - py.test --cov=spectrum_overload spectrum_overload/ --cov-report term-missing
- py.test --cov=spectrum_overload --cov-report term-missing
- pytest --cov=spectrum_overload --cov-report term-missing --durations 5

after_success:
- coveralls
- codeclimate-test-reporter
13 changes: 8 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
# spectrum_overload [![Build Status](https://travis-ci.org/jason-neal/spectrum_overload.svg)](https://travis-ci.org/jason-neal/spectrum_overload) [![Coverage Status](https://coveralls.io/repos/github/jason-neal/spectrum_overload/badge.svg?branch=develop)](https://coveralls.io/github/jason-neal/spectrum_overload?branch=develop)
# spectrum_overload
| Branch | Docs | Build | Coverage | Code Climate | Code Issues |
| :----: | :---: | :-----: | :----: | :----------: | :---------: |
| master | [![Documentation Status](https://readthedocs.org/projects/spectrum-overload/badge/?version=latest)](http://spectrum-overload.readthedocs.io/en/latest/?badge=latest) | [![Build Status](https://travis-ci.org/jason-neal/spectrum_overload.svg?branch=master)](https://travis-ci.org/jason-neal/spectrum_overload) | [![Coverage Status](https://coveralls.io/repos/github/jason-neal/spectrum_overload/badge.svg?branch=master)](https://coveralls.io/github/jason-neal/spectrum_overload?branch=master) [![Test Coverage](https://codeclimate.com/github/jason-neal/spectrum_overload/badges/coverage.svg)](https://codeclimate.com/github/jason-neal/spectrum_overload/coverage) | [![Code Climate](https://codeclimate.com/github/jason-neal/spectrum_overload/badges/gpa.svg)](https://codeclimate.com/github/jason-neal/spectrum_overload)[![Issue Count](https://codeclimate.com/github/jason-neal/spectrum_overload/badges/issue_count.svg)](https://codeclimate.com/github/jason-neal/spectrum_overload) | [![Code Issues](https://www.quantifiedcode.com/api/v1/project/6e918445f6f344c1af9c32f50718082e/snapshot/origin:master:HEAD/badge.svg)](https://www.quantifiedcode.com/app/project/6e918445f6f344c1af9c32f50718082e?branch=origin/master) |
| develop | [![Documentation Status](https://readthedocs.org/projects/spectrum-overload/badge/?version=develop)](http://spectrum-overload.readthedocs.io/en/latest/?badge=develop) | [![Build Status](https://travis-ci.org/jason-neal/spectrum_overload.svg?branch=develop)](https://travis-ci.org/jason-neal/spectrum_overload) | [![Coverage Status](https://coveralls.io/repos/github/jason-neal/spectrum_overload/badge.svg?branch=develop)](https://coveralls.io/github/jason-neal/spectrum_overload?branch=develop) [![Test Coverage](https://codeclimate.com/github/jason-neal/spectrum_overload/badges/coverage.svg?branch=develop)](https://codeclimate.com/github/jason-neal/spectrum_overload/coverage?branch=develop) | [![Code Climate](https://codeclimate.com/github/jason-neal/spectrum_overload/badges/gpa.svg?branch=develop)](https://codeclimate.com/github/jason-neal/spectrum_overload?branch=develop)[![Issue Count](https://codeclimate.com/github/jason-neal/spectrum_overload/badges/issue_count.svg?branch=develop)](https://codeclimate.com/github/jason-neal/spectrum_overload?branch=develop) | [![Code Issues](https://www.quantifiedcode.com/api/v1/project/6e918445f6f344c1af9c32f50718082e/snapshot/origin:develop:HEAD/badge.svg)](https://www.quantifiedcode.com/app/project/6e918445f6f344c1af9c32f50718082e?branch=origin/develop) |

## Overview
The purpose of this was project was to learn how to use and create Classes, and to create a Spectrum object to use within my Phd work.

The main goals of this project are basically complete.

- create a class to contain spectrum
- automatic interpolation
- automatic interpolation
- overloaded operators
especially
- Spectral division (SpectrumA / SpectrumB )
Expand All @@ -17,7 +21,7 @@ especially
Currently to install and use Spectrum class for your own projects.

clone the git repository where you want it:

https://github.com/jason-neal/spectrum_overload.git

cd into the downloaded directory:
Expand All @@ -31,7 +35,7 @@ and install using:

## Usage
To use import the class using :

from spectrum_overload import Spectrum
...
my_spectrum = Spectrum.Spectrum(flux, xaxis)
Expand Down Expand Up @@ -78,4 +82,3 @@ Some tasks still to do:
- Improve Documentation
- Generate Calibration solution (outside spectrum class)?
- Push a version to pypi

64 changes: 58 additions & 6 deletions docs/index.rst
Original file line number Diff line number Diff line change
@@ -1,17 +1,25 @@
.. Spectrum documentation master file, created by
sphinx-quickstart on Sun Sep 11 23:45:23 2016.
.. image:: https://readthedocs.org/projects/spectrum-overload/badge/?version=latest
:target: http://spectrum-overload.readthedocs.io/en/latest/?badge=latest
:alt: Documentation Status

.. image:: https://travis-ci.org/jason-neal/spectrum_overload.svg?branch=master
:target: https://travis-ci.org/jason-neal/spectrum_overload

.. image:: https://coveralls.io/repos/github/jason-neal/spectrum_overload/badge.svg?branch=master
:target: https://coveralls.io/github/jason-neal/spectrum_overload?branch=master

.. image:: https://codeclimate.com/github/jason-neal/spectrum_overload/badges/gpa.svg
:target: https://codeclimate.com/github/jason-neal/spectrum_overload
:alt: Code Climate

.. _home:

=============================================
Welcome to spectrum_overload's documentation!
=============================================
.. image:: https://travis-ci.org/jason-neal/spectrum_overload.svg?branch=develop
:target: https://travis-ci.org/jason-neal/spectrum_overload

.. image:: https://coveralls.io/repos/github/jason-neal/spectrum_overload/badge.svg?branch=develop
:target: https://coveralls.io/github/jason-neal/spectrum_overload?branch=develop


Spectrum_overload is to manipulate astronomical spectra in a spectrum class with :ref:`overloaded operators <overloaded_operators>`.
This means that you can easily divide and subtract spectra from each other using the math operators ``+``, ``-``, ``*``, ``/``, ``**`` keeping the wavelength, flux and headers together.
Expand Down Expand Up @@ -47,6 +55,50 @@ Submit `issues <https://github.com/jason-neal/spectrum_overload/issues>`_, sugge

This is my first attempt at creating classes, and packaging a python project so any *helpful* feedback is appreciated.

Badges
======
**master**

.. image:: https://readthedocs.org/projects/spectrum-overload/badge/?version=latest
:target: http://spectrum-overload.readthedocs.io/en/latest/?badge=latest
:alt: Documentation Status
.. image:: https://travis-ci.org/jason-neal/spectrum_overload.svg?branch=master
:target: https://travis-ci.org/jason-neal/spectrum_overload
:alt: Build Status
.. image:: https://coveralls.io/repos/github/jason-neal/spectrum_overload/badge.svg?branch=master
:target: https://coveralls.io/github/jason-neal/spectrum_overload?branch=master
:alt: Test Coverage
.. image:: https://codeclimate.com/github/jason-neal/spectrum_overload/badges/gpa.svg
:target: https://codeclimate.com/github/jason-neal/spectrum_overload
:alt: Code Climate
.. image:: https://codeclimate.com/github/jason-neal/spectrum_overload/badges/issue_count.svg
:target: https://codeclimate.com/github/jason-neal/spectrum_overload
:alt: Issue Count
.. image:: https://www.quantifiedcode.com/api/v1/project/6e918445f6f344c1af9c32f50718082e/badge.svg?branch=master
:target: https://www.quantifiedcode.com/app/project/6e918445f6f344c1af9c32f50718082e
:alt: Code Issues

**develop**

.. image:: https://readthedocs.org/projects/spectrum-overload/badge/?version=develop
:target: http://spectrum-overload.readthedocs.io/en/develop
:alt: Documentation Status
.. image:: https://travis-ci.org/jason-neal/spectrum_overload.svg?branch=develop
:target: https://travis-ci.org/jason-neal/spectrum_overload?branch=develop
:alt: Build Status
.. image:: https://coveralls.io/repos/github/jason-neal/spectrum_overload/badge.svg?branch=develop
:target: https://coveralls.io/github/jason-neal/spectrum_overload?branch=develop
:alt: Test Coverage
.. image:: https://codeclimate.com/github/jason-neal/spectrum_overload/badges/gpa.svg?branch=develop
:target: https://codeclimate.com/github/jason-neal/spectrum_overload?branch=develop
:alt: Code Climate GPA
.. image:: https://codeclimate.com/github/jason-neal/spectrum_overload/badges/issue_count.svg?branch=develop
:target: https://codeclimate.com/github/jason-neal/spectrum_overload?branch=develop
:alt: Issue Count
.. image:: https://www.quantifiedcode.com/api/v1/project/6e918445f6f344c1af9c32f50718082e/badge.svg?branch=develop
:target: https://www.quantifiedcode.com/app/project/6e918445f6f344c1af9c32f50718082e?branch=develop
:alt: Code Issues


Indices and tables
==================
Expand Down

0 comments on commit e5d9694

Please sign in to comment.