;+
; NAME:
;     GET_DAILY_STRUCT
; PURPOSE:
;     Define structure used for holding the results of a DAILY phase
;     calibration.
; CATEGORY:
;     OVRO APC STRUCT
; CALLING SEQUENCE:
;     dailyphz = get_daily_struct()
; INPUTS:
; OPTIONAL (KEYWORD) INPUT PARAMETERS:
; ROUTINES CALLED:
; OUTPUTS:
;     dailyphz    an empty reference calibration structure
; COMMENTS:
;     This structure requires the use of a pointer to the AMF array,
;     because the array size may vary and structure definitions
;     must be static.  To use, always free the existing pointer and
;     then create a new one. For example:
;
;       ptr_free,dailyphz.pamf
;       dailyphz.pamf = ptr_new(amf)
;
;     This will ensure that the memory area pointed to by the
;     existing pointer is freed back to the memory pool.
;
; SIDE EFFECTS:
; RESTRICTIONS:
; MODIFICATION HISTORY:
;     Written 08-Jun-2000 by Dale E. Gary
;     16-Jul-2000  DG
;       Added the POFF array to the structure.
;-
function get_daily_struct

   ; Define DAILY phase calibration structure
   dailyphz = {daily, $
                tls: get_tl_struct(), $  ; The Time/Label struct giving t_ref
               poff:       fltarr(8), $  ; The phase offset for each ant
               pslp:       fltarr(8), $  ; The phase slope with freq for each ant
               perr:       fltarr(8), $  ; The std error in phase slopes
               pamf:       ptr_new(0)}   ; Pointer to an array of size (5,NF,NBL)
                                         ;  containing the AMPHIT result for this
                                         ;  PCAL scan.

return,dailyphz
end