Getting Started Documentation Glish Learn More Programming Contact Us
Version 1.9 Build 1488
News FAQ
Search Home


next up previous contents index
Next: imageprofilesupport.setnoprofile - Function Up: imageprofilesupport - Tool Previous: imageprofilesupport.setabcissaunit - Function


imageprofilesupport.setcoordinatesystem - Function



Package general
Module images
Tool imageprofilesupport


Set a new coordinate system


Synopsis
setcoordinatesystem(csys, shp, resetref)


Arguments

csys in New coordinate system
    Allowed: Coordsys tool
shp in Shape of associated image
    Allowed: Vector of integer
resetref in Reset Reference Frame to Native of new Coordinate System
    Allowed: T or F
    Default: F



Returns
Integer or fail



Description

This function sets a new coordinate system and associated image shape. This function will update the x-axis menus appropriately.

After calling this function, you must remake the abcissa and ordinate profiles (functions makeabcissa and makeordinate or setordinate).

The argument resetref is used to reset any reference frame selection (in the GUI) back to the native one contained in the new coordinate system (or any extra frame conversion currently set in the supplied coordinate system). Otherwise, the GUI selection is left as it is. For example, the user might have asked to convert a Spectral coordinate to TOPO. If resetref=F TOPO is left selected and conversions are made to it. If resetref=T then, if the new coordinate system has LSRK say as the native frame, then LSRK is now selected in the GUI and no extra conversions are made.



Example
- im := image('ngc1313.cube')              
- csys := im.coordsys()                    
- shp := im.shape()                        
- axis := 3;
- p := imageprofilesupport(csys=csys, shp=shp)
- p.setprofileaxis(axis);
- p.makemenus()
- pos := csys.referencepixel()             
- p.makeabcissa(pos)                       
- r := drm.box()
- p.makeordinate(im, r)
- p.plot()                                 
-
- im2 := image('ngc1399.cube')              
- csys2 := im2.coordsys();
- shp2 :=  im2.shape();
- axis2 := 1;
- p.setprofileaxis(axis2)
- p.setcoordinatesystem(csys2, shp2)
- pos := csys.referencepixel()             
- p.makeabcissa(pos);
- p.makeordinate(im2, r)
- p.plot()




next up previous contents index
Next: imageprofilesupport.setnoprofile - Function Up: imageprofilesupport - Tool Previous: imageprofilesupport.setabcissaunit - Function   Contents   Index
Please send questions or comments about AIPS++ to aips2-request@nrao.edu.
Copyright © 1995-2000 Associated Universities Inc., Washington, D.C.

Return to AIPS++ Home Page
2006-08-01