Skip to content
This repository has been archived by the owner on Jul 22, 2021. It is now read-only.

Commit

Permalink
Completed incorporation of the interfaces documentation
Browse files Browse the repository at this point in the history
WIP #237
  • Loading branch information
stscieisenhamer committed Dec 29, 2016
1 parent 33f7191 commit d7db979
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 1 deletion.
14 changes: 14 additions & 0 deletions docs/source/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,21 @@ Interfaces
.. automodapi:: specviz.interfaces
:no-heading:

Model Factories
^^^^^^^^^^^^^^^
.. automodapi:: specviz.interfaces.factories
:no-heading:
:no-main-docstr:
:headings:""

Model Initialization
^^^^^^^^^^^^^^^^^^^^
.. automodapi:: specviz.interfaces.initializers
:no-heading:
:no-main-docstr:
:headings:""


I/O module
----------
.. automodapi:: specviz.io
Expand Down
5 changes: 5 additions & 0 deletions specviz/interfaces/factories.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@
# THIRD-PARTY
from astropy.modeling import models, fitting

__all__ = [
'Factory',
'FitterFactory',
'ModelFactory',
]

class Factory(object):
"""
Expand Down
8 changes: 7 additions & 1 deletion specviz/interfaces/initializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@

from ..analysis.models import spline, blackbody

__all__ = [
'initialize'
]

AMPLITUDE = 'amplitude'
POSITION = 'position'
WIDTH = 'width'
Expand Down Expand Up @@ -236,7 +240,9 @@ def _setattr(instance, mname, pname, value):

def initialize(instance, x, y):
"""
Main entry point. X and Y are for now Quantity arrays with the
Initialize given model.
X and Y are for now Quantity arrays with the
independent and dependent variables. It's assumed X values
are stored in increasing order in the array.
Expand Down

0 comments on commit d7db979

Please sign in to comment.