Small improvements to docs

Preserved requested spectral unit

Tidy up initialization of new cubes from modified version of existing cubes.

Set _spectral_unit only in with_spectral_unit

Minor fix

Pass new meta

Fix propagation of spectral unit

Check that WCS auto-changes unit and that spectral_unit is needed

Fix error in write

Change clobber -> overwrite in write

add determine_vconv_from_ctype function

add tests for determinator

add convenience function for accessing velocity convention from a cube

WIP: progress toward appropriate rest frequency conversion

the tests were much harder than the original code...

Small improvements to quickstart example

Improvements to docs

Change rest_frequency to rest_value

Don’t show stokes section until it’s written

Added spectral docs section

Allow string input for velocity convention

Remove rest_value from closest_spectral_channel and spectral_slab

Combine subsets.rst and spectral.rst into docs about modifying/manipulating cubes.

Re-order docs about accessing data and masking.

Fix small mistakes in docs

Mention what happens if a slice is not given for the data.

Update docs on extracting spectral slab

Added note about stokes

Implemented wording comments by @keflavich

make WCS comparison more permissive; WCS are most likely to be identical
if one has some info (e.g. equinox) and the other does not, so it is
better to warn than Raise for this case.

print->logging.debug and added a 32 vs 64 bit test

Merge astropy:package-template affiliated package infrastructure

Fix docs warnings

Fix more docs warnings

Fix indentation warning

Renamed CHANGES to CHANGES.rst and added initial content

Added license

Updated MANIFEST.in

Preparing release 0.1

Back to development: 0.2

Use spectral-cube instead of spectral_cube for the distribution name

Updated URL in setup.py

Added astropy_helpers to RTD pip requirements

Use default Sphinx theme

allow slices (integer views, rather than Slice views) to be created

cleanup of debugging and add a warning about REST stuff
(I'm not sure this is supposed to be in the slices branch, but I made
the change and I think it's important)

add support for air wavelengths (1-way, no tests)

fill in missing dict entry

wavelength isn't a type

add warning about air wavelength support

moments need to preserve the spectral units, or everything goes right to
hell

deep changes to how spectral units are tracked and maintained

pix_cen was already accounting for units

header/meta BUNIT case consistency: BUNIT should always be capitalized

warn if _meta['BUNIT'] is unparseable and set unit to None

changed shape validation to use is_broadcastable (thanks
@ChrisBeaumont!)

fix verification: _mask instead of _data for booleanarray

add unit tests for broadcastability check, and use a faster version

Changelog updates for today's pulls

add hdu attribute to cube

data cannot be a quantity

bugfix: _mask[view] invalid if _mask not defined

Update CHANGES.rst

Add 'ignored keywords' to WCS checking

Update to v0.4 of the affiliated package template

make apply_along_axis public and have it return a projection

cleanup

more cleanup, but also note that the previous commit renamed
"apply_along_axis" to "apply_function", which is more accurate

fix test: unnecessary comma added

fix return type from _apply_numpy_function.   Now that I think about it,
that should probably be made public too

make apply_numpy_function public and have sum, min, max return
projections by default

forgot an underscore

whitespace

make callspec of apply_function and apply_numpy_function same

added changelog entry

fix bug: this was introduced when branches were switched and data was
discarded, which I've never seen before

add documentation, remove locals() reference

out is None check

sum, max, min should not return projections if naxis is not a single
integer

implement minimal cube slicing: super useful for region extraction

First pass at getting spectral-cube's yt interface up to speed with the latest changes in yt 3.0.

Attempting to get some feature parity between yt 2.x and 3.x

Attempting to get better convergence between yt 2.x and 3.0 implementations of to_yt

Adding a yt2world method, cleaning up the documentation a bit

Needed this line

Cleaning up documentation

Followed @astrofrog's suggestion and made these methods take the spectral_cube argument

yt installation line for Travis

Only allow yt tests for recent numpy versions

Only need to test 1.7

Replacing pf with ds to reflect yt 3.0

Some unit tests for yt

Adding assert_array_equal for integer ndarrays

Most of these tests pass now, but there's a nasty bug that I need to track down.

These tests won't pass completely until yt 3.0.1 is installed in Anaconda.

First pass at getting spectral-cube's yt interface up to speed with the latest changes in yt 3.0.

Attempting to get better convergence between yt 2.x and 3.0 implementations of to_yt

Cleaning up documentation

Followed @astrofrog's suggestion and made these methods take the spectral_cube argument

Only allow yt tests for recent numpy versions

Only need to test 1.7

split out yt tests

fix yt test setup

make world2yt and yt2world private functions

whitespace/pep8

add a link to the yt docs

skip failing test: tests pass!

use StrictVersion for all yt version comparisons

fix test: yt_version needs to be defined even if yt can't be imported

to_yt returns a YtCube object

pep8 -> package naming convention
fix tests: methods of correct objects

one more excess spectral_factor removed

use zero-indexed coordinates in yt2world/world2yt

allow 0 or 1 indexing in yt2world and back.  Clean their docs a little

use numpy >= 1.8

>= not allowed!

fix the bugs in the initial commit

spec out subcube

subcube implemented

fix an x/z swap and add tests

implement pyregion-based region extraction

comments only (notes for future dev)

attempts to write tests led to discoveries of issues in the pyregion
tool

the test passes now because it doesn't do anything

add .mean method

fix booleanarraymask broadcasting rules and Slicing - slicing should use
filled_data, not _data

fix tests: kwargs instead of positional args

add a test of boolean array broadcasting

skip multiaxis squash tests if version<1.7

add a 'quicklook' tool to the projection class using aplpy

FITSFigure.show...

only make FITSFigure once

add changelog entry

add a note about broadcasting masks

update changelog and add some more examples to the docs

update the yt docs to use the new API (with warning about possible
interpration amibiguity in the pixel coordinates)

add a history entry to the header when writing out a FITS file

a test for check_endian

tests to make sure check_endian = off leaves data untouched

add bottleneck installation to travis

skip bottleneck tests if bottleneck not imported

change version of bottleneck to install

fix a ridiculously silly bug in which the computed result wasn't
returned

cube should preserve the input header, since it almost certainly
contains important metadata about the origin of the data, etc.

track header around

propagate header into _new_cube_with

split out ytcube into its own file and make a quick movie rendering

try yt imports.  travis has with/without yt for 2.7 tests

add quick isocontour and docs

add example movie

amend?

remove excess comments

add some transfer function tools to beef up rendering, and fix the
center to be the correct center when the cube has been stretched

remove codec from ffmpeg

update WCS slicing to fix bug noted in astropy #2909

rename function

add slicing tests

add WCS slice tests

update astropy_helpers

header needs to be updated with the appropriate NAXIS

add tests for header

StokesCube should pass header to regular cube

can't have any WCS information transmitted from the old header

header-related issues: why is it so hard to REMOVE wcs information from
a header?
Also, yt version-checking

v0.2.0

v0.2.0->v0.2.dev

allow prefixes for image files created in the yt movies and allow
reindexing

fix usage of prefix, log keyword args

formatting typo

left out one prefix use

masks' _include should be able to operate without data being given
(masks are defined with or without data to mask)

add changelog entry

add a very simple mask == mask test

minor tweaks to the yt viz tools

add a flattened_world feature so that the world coordinates of each
pixel the flattened data array can be retrieved

added CLASS LMV reader

added class format to reader, auto-format-determinator

LMV reader updated, tested on real files

fix headers in class_lmv

add a strong warning

refactor: reader->io

fix imports in reader

fix a yt version check in the tests: yt-dev versions were not parsed
properly

Combined commits: fix a minor issue with np.nansum behavior changing
from 1.8-1.9
add numpy 1.8 nanfunctions to ensure np1.8 = np1.9 behavior

udpate tests

moments no longer uses np.nansum (np_compat.nansum instead)

remove all but nansum, nanmin, nanmax

import things that needed to be imported (oops)

correct imports and add support functions for numpy 1.7.  If this fails
on 1.6, 3.2, I suggest we drop support for them

completely copying over numpy functions was way too much and would have
lead to a huge maintenance burden.  Instead, just overload nansum and
leave the rest untouched

remove np_compat; we're just going to change the tests

remove np_compat

1.9 nanish override; everything else gets to stay the same

separate concerns as per @ChrisBeaumont's suggestion

don't convert to np.float - can double data size!  (very bad for large
cubes)

apparently data MUST be coerced to floating point unless it's already a
float.  I don't understand why.  Tests are still broken in a place I
don't understand

cleanup data[view]/dtype logic

add np 1.9 to travis as the default, with the expectation that this will
break everything

travis: more tests with 1.8 vs 1.9.  This will still fail, but at least
it shouldn't error

allbadtonan wrapper instead of a single-case override; allows general
use and application within the test suite too

add the @!#$ file

quicklook: backup plan if celestial + spectral axes ("PV" diagram)

preserve the spectral units when creating an output header

add tests

fix bug + regression test

preserving units: most of this work was already done and just wasn't
passed to header.  Added unit preservation (based on header) to __init__
now

basic implementation of 1D *spectral* slices (WCS still has trouble with
non-spectral 1D slices)

fix a call to _new_cube_with and add a .value property to return a
unitless copy of self

implement @ChrisBeaumont's comments

REMOVE np.asarray: it does bad things to Quantities!

whitespace

asarray for value.ndim!  THAT's how you do it... riiight.

Updated package template to v0.4.1 (includes update of astropy-helpers to v0.4.3)

Add Zenodo DOI

first attempt at a to_glue machine.  Required fixing some bugs in
__getitem__ but that's no problem

the glue_app becomes part of the cube now so that subsequent calls add
the dataset to an existing session

allow a glue application to be specified.  add docstrings

attempt to accept updates of data collections

have to add cubes to the dataset object, not the datacollection

need to check component labels, not 'components'

autoload glue viewer

add start_gui keyword

fix FITS reading bug

add a simple to_pvextractor tool

docstring for to_pvextractor

add a quicklook tool for spectra

add quick_look documentation

fix spectral quicklook wcs

add a quicklook tool for spectral slices

fix CASA .image reading: should not assume 3d by default, since usually
stored as 4d

need to pass CASA's units into SpectralCube
(also, should check for importerror with aplpy quicklooks)

fix a merge mistake in spectral quicklook

updated CHANGES

Merge branch 'master' of http://github.com/radio-astro-tools/spectral-cube

* 'master' of http://github.com/radio-astro-tools/spectral-cube: (231 commits)
  update apt-get listings (fixes graphviz install issue)
  bugfix: with_mask should be usable when no `_mask` is defined
  clean up tests of broadcastability
  with_mask checks for broadcastable, not equal shape
  add 'save' to quicklooks
  updated CHANGES
  fix a merge mistake in spectral quicklook
  need to pass CASA's units into SpectralCube (also, should check for importerror with aplpy quicklooks)
  fix CASA .image reading: should not assume 3d by default, since usually stored as 4d
  add a quicklook tool for spectral slices
  fix spectral quicklook wcs
  add quick_look documentation
  add a quicklook tool for spectra
  docstring for to_pvextractor
  add a simple to_pvextractor tool
  fix FITS reading bug
  Add Zenodo DOI
  add start_gui keyword
  autoload glue viewer
  need to check component labels, not 'components'
  ...

Conflicts:
	.travis.yml
	CHANGES.rst
	spectral_cube/masks.py
	spectral_cube/spectral_cube.py
	spectral_cube/tests/test_masks.py

Putting things in this format was causing problems with yt