Changeset 530


Ignore:
Timestamp:
03/01/05 15:12:17 (19 years ago)
Author:
mar637
Message:

*added get_fit

  • added more commands()
Location:
trunk/python
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/python/__init__.py

    r513 r530  
    215215from scantable import *
    216216from asaplinefind import *
     217from asapfit import *
    217218
    218219from numarray import logical_and as mask_and
     
    232233
    233234__date__ = '$Date$'
    234 __version__  = '0.9'
     235__version__  = '0.99'
    235236
    236237def list_scans(t = scantable):
     
    285286            nbeam,nif,nchan,npol - the number of beams/IFs/Pols/Chans
    286287            history         - print the history of the scantable
    287 
     288            get_fit         - get a fit which has been stored witnh the data
    288289            average_time    - return the (weighted) time average of a scan
    289290                              or a list of scans
     
    321322                              commited.
    322323            fit             - execute the actual fitting process
     324            store_fit       - store the fit paramaters in the data (scantable)
    323325            get_chi2        - get the Chi^2
    324326            set_scan        - set the scantable to be fit
     
    339341                              what is to be plotted 'colour stacked'
    340342                              and what 'panelled'
    341             set_range       - set the abcissa 'zoom' range
     343            set_cursor      - only plot a selected part of the data
     344            set_range       - set a 'zoom' window
    342345            set_legend      - specify user labels for the legend indeces
    343346            set_title       - specify user labels for the panel indeces
  • trunk/python/scantable.py

    r524 r530  
    10611061            # not using a mask
    10621062            bscan = scan.poly_baseline(order=3)
    1063         """
     1063        """('', 'TOPO', 'RADIO', 'TOPO')
    10641064        if insitu is None: insitu = rcParams['insitu']
    10651065        varlist = vars()
     
    13581358        s._add_history("operator /", varlist)
    13591359        return s
     1360
     1361    def get_fit(self, row=0):
     1362        """
     1363        Print or return the stored fits for a row in the scantable
     1364        Parameters:
     1365            row:    the row which the fit has been applied to.
     1366        """
     1367        if row > self.nrow():
     1368            return
     1369        from asap import asapfit
     1370        fit = asapfit(self._getfit(row))
     1371        if self._vb:
     1372            print fit
     1373            return
     1374        else:
     1375            return fit.as_dict()
    13601376
    13611377    def _add_history(self, funcname, parameters):
Note: See TracChangeset for help on using the changeset viewer.