Return to directory of Todd's CASA extensions

Takes two lists, and if the first list is in decreasing order, then it inverts both lists. Useful for forcing a spectrum to have increasing frequency vs. channel.


au.checkOrder(inpFreq ,inpData)
  • inpFreq: the x-axis values
  • inpData: the y-axis values
  • [x-axis values, y-axis values, reversed] where reversed is a Boolean with values: 0="unchanged", 1="lists have been inverted so that x-axis is in increasing order"


CASA <3>: au.checkOrder([0,10],[1.15,1.7])
  Out[3]: ([0, 10], [1.15, 1.7], 0)
CASA <4>: au.checkOrder([0,-10],[1.15,1.7])
  Out[4]: ([-10, 0], [1.7, 1.15], 1)

-- ToddHunter - 2014-08-13

This topic: ALMA > TWikiUsers > ToddHunter > CasaExtensions > CheckOrder
Topic revision: 2014-08-13, ToddHunter
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding NRAO Public Wiki? Send feedback