;+ ; NAME: ; decstrf ; PURPOSE: (one line) ; Convert declination in radians to an ASCII string. ; DESCRIPTION: ; ; CATEGORY: ; Astronomy ; CALLING SEQUENCE: ; str = decstrf(dec, places) ; INPUTS: ; dec - Declination, in radians, to be converted to a string. May ; a vector, in which case the output will be a vector. ; OPTIONAL INPUT PARAMETERS: ; places - Resolution of output string (integer). ; = -7 nearest hour. +DD ; = -6 nearest 30 minutes. +DD:(00,30) ; = -5 nearest 15 minutes. +DD:(00,15,30,45) ; = -4 nearest 10 minutes. +DD:M0 ; = -3 nearest 5 minutes. +DD:M(0,5) ; = -2 nearest minute. +DD:MM ; = -1 nearest ten seconds. +DD:MM:S0 ; = 0 nearest second. +DD:MM:SS ; = 1 nearest tenth of a second. +DD:MM:SS.s ; = 2 nearest hundredth of a second. +DD:MM:SS.ss ; = 3 nearest thousandth of a second. +DD:MM:SS.sss ; KEYWORD INPUT PARAMETERS: ; none ; KEYWORD OUTPUT PARAMETERS: ; none ; OUTPUTS: ; str - Output string for the converted dec ; COMMON BLOCKS: ; SIDE EFFECTS: ; RESTRICTIONS: ; PROCEDURE: ; Call the PROCEDURE decstr ; MODIFICATION HISTORY: ; Written 2006 Feb 27, by Leslie Young, SwRI ;- function decstrf, dec, places if n_params() eq 1 then places = 3 decstrlay, dec, places, str return, str end