w $SSW/yohkoh/ucon/idl/foley/w.pro
[Previous] [Next]
 NAME:
  w.pro  
 PURPOSE
  Spawn Unix 'w' command. 

 CALLING SEQUENCE
  none
 INPUT
  none     
 OUTPUT
  none
 OPTIONAL OUTPUT
  none	
 OPTIONAL KEYWORD INPUT
  none	
 RESTRICTION
  none

 HISTORY
  Written CAF 2 MAY 96 : caf@mssl.ucl.ac.uk


w256 [2] $SSW/yohkoh/ucon/idl/acton/w256.pro
[Previous] [Next]
NAME:
	w256
PURPOSE
	To assure an IDL color table with the full 256 colors.
CALLING EXAMPLE
	w256
RESULT
	IDL will use full 256 colors for the rest of the session.
	In order to achieve this the color table of a window is only
	correct when the cursor is on a window.  The function here
	is like the result of the Netscape -install result.
RESTRICTIONS
	This will only work if done BEFORE any other windows are
	opened with a "window" or "wdsef" command.  Do it first thing
	upon beginning a session.
HISTORY
	LWA, 6/17/98, put online in /ucon area.
		      IDL's shortest program!
 CALLED BY
	MAKE_GIFS, RTMVI [1], UPDATE_MPG, rt, rtpng


WBDA [1] $SSW/yohkoh/bcs/idl/atest/wbda.pro
[Previous] [Next]
 NAME:
             WBDA
 PURPOSE:
             to provide widget interface to Yohkoh BCS data
 CALLING SEQUENCE:
             WBDA
 INPUTS:
             bda_index = BDA index structure array
             bda_data  = BDA spectral data  array 
 OPTIONAL OUTPUTS:
             bsc_index = BSC index structure 
             bsc_data  = BSC data structure
 CALLS: ***
	ATIME [1], ATIME [2], BCS_CLEAN [1], BCS_CLEAN [2], BCS_DECOMP, BREAK_FILE [1]
	BREAK_FILE [2], BREAK_FILE [3], CHKLOG [1], CHKLOG [2], CLEANPLOT [1]
	CLEANPLOT [2], CLEANPLOT [3], CLEAR_UTPLOT [1], CLEAR_UTPLOT [2], CONCAT_DIR [1]
	CONCAT_DIR [2], CONCAT_DIR [3], DATATYPE [1], DATATYPE [2], DATATYPE [3]
	DATA_PATHS, DERIV, GT_BSC_BINCAL [1], GT_BSC_BINCAL [2], LOC_FILE [1]
	LOC_FILE [2], LOC_FILE [3], MK_BSA_STC [1], MK_BSA_STC [2], MK_BSC_DATA [1]
	MK_BSC_DATA [2], PLOTSPEC, RD_BDA [1], RD_BDA [2], Rd_Roadmap [2], SET_UTLABEL
	TEST_OPEN, TRIM, TWIDGET, WBDA_EVENT, WFLIST, WR_ASC, XDISPLAYFILE [1]
	XDISPLAYFILE [2], XMANAGER, XMENU [1], XMENU [2], XPDMENU, XREGISTERED
	anytim2ex [1], anytim2ex [2], break_file [4], clearplot [1], clearplot [2]
	concat_dir [4], ext_bcschan [1], ext_bcschan [2], gt_day [1], gt_day [2]
	gt_time [1], gt_time [2], gt_total_cnts [1], gt_total_cnts [2]
	mk_bsa_interv [1], mk_bsa_interv [2], plotltc [1], plotltc [2], rd_roadmap [1]
	set_hard, str_checks [1], str_checks [2]
 RESTRICTIONS: 
             needs X-windows 
 MODIFICATION HISTORY:
             Oct'92, DMZ (ARC) -- written
             Oct'93, DMZ -- changed bsc_index and bsc_data to argument inputs
             1- Jun'94, DMZ -- fixed potential bug in BDA roadmap/index usage
            30- Jun'94, DMZ -- separated lightcurve and spectrum window bases


WBDA [2] $SSW/yohkoh/bcs/idl/bda/wbda.pro
[Previous] [Next]
 NAME:
             WBDA
 PURPOSE:
             to provide widget interface to Yohkoh BCS data
 CALLING SEQUENCE:
             WBDA
 INPUTS:
             bda_index = BDA index structure array
             bda_data  = BDA spectral data  array 
 OPTIONAL OUTPUTS:
             bsc_index = BSC index structure 
             bsc_data  = BSC data structure
 CALLS: ***
	ATIME [1], ATIME [2], BCS_CLEAN [1], BCS_CLEAN [2], BCS_DECOMP, BREAK_FILE [1]
	BREAK_FILE [2], BREAK_FILE [3], CHKLOG [1], CHKLOG [2], CLEANPLOT [1]
	CLEANPLOT [2], CLEANPLOT [3], CLEAR_UTPLOT [1], CLEAR_UTPLOT [2], CONCAT_DIR [1]
	CONCAT_DIR [2], CONCAT_DIR [3], DATATYPE [1], DATATYPE [2], DATATYPE [3]
	DATA_PATHS, DERIV, GT_BSC_BINCAL [1], GT_BSC_BINCAL [2], LOC_FILE [1]
	LOC_FILE [2], LOC_FILE [3], MK_BSA_STC [1], MK_BSA_STC [2], MK_BSC_DATA [1]
	MK_BSC_DATA [2], PLOTSPEC, RD_BDA [1], RD_BDA [2], Rd_Roadmap [2], SET_UTLABEL
	TEST_OPEN, TRIM, TWIDGET, WBDA_EVENT, WFLIST, WR_ASC, XDISPLAYFILE [1]
	XDISPLAYFILE [2], XMANAGER, XMENU [1], XMENU [2], XPDMENU, XREGISTERED
	anytim2ex [1], anytim2ex [2], break_file [4], clearplot [1], clearplot [2]
	concat_dir [4], ext_bcschan [1], ext_bcschan [2], gt_day [1], gt_day [2]
	gt_time [1], gt_time [2], gt_total_cnts [1], gt_total_cnts [2]
	mk_bsa_interv [1], mk_bsa_interv [2], plotltc [1], plotltc [2], rd_roadmap [1]
	set_hard, str_checks [1], str_checks [2]
 RESTRICTIONS: 
             needs X-windows 
 MODIFICATION HISTORY:
             Oct'92, DMZ (ARC) -- written
             Oct'93, DMZ -- changed bsc_index and bsc_data to argument inputs
             1- Jun'94, DMZ -- fixed potential bug in BDA roadmap/index usage
            30- Jun'94, DMZ -- separated lightcurve and spectrum window bases


WBS_DB $SSW/yohkoh/ucon/idl/hudson/wbs_db.pro
[Previous] [Next]
 NAME:
 	WBS_DB
 PURPOSE:
	re-reformat the data section of WBS data into (16,39) integer arrays
 INPUTS:
	filename (e.g. /yd6/flares/wda911115.0000), time of desired record
	  (e.g. 15-nov-91 22:37:38)
 OUTPUTS: 
	header string
	header integers
	data in integer array format, (16,39,2)
 CALLS: ***
	HXT_DECOMP, Int2Ex [1], Int2Ex [2], RD_WDA, Rd_Roadmap [2], fmt_tim [1], fmt_tim [2]
	gt_day [1], gt_day [2], gt_dp_mode [1], gt_dp_mode [2], gt_dp_rate [1]
	gt_dp_rate [2], gt_time [1], gt_time [2], rd_roadmap [1], tim2dset [1]
	tim2dset [2]
 HISTORY:
 	HSH, KO, written May 29, 1992


WBS_DB2 $SSW/yohkoh/ucon/idl/morrison/wbs_db2.pro
[Previous] [Next]
 NAME:
 	WBS_DB2
 PURPOSE:
	re-reformat the data section of WBS data into (16,39) integer arrays
 INPUTS:
	filename (e.g. /yd6/flares/wda911115.0000), time of desired record
	  (e.g. 15-nov-91 22:37:38)
 OUTPUTS: 
	header string
	header integers
	data in integer array format, (16,39,2)
 CALLS: ***
	HXT_DECOMP, RD_WDA, Rd_Roadmap [2], anytim2ex [1], anytim2ex [2], anytim2ints [1]
	anytim2ints [2], dprate2sec [1], dprate2sec [2], fmt_tim [1], fmt_tim [2]
	gt_dp_mode [1], gt_dp_mode [2], gt_dp_rate [1], gt_dp_rate [2], gt_time [1]
	gt_time [2], rd_roadmap [1], tim2dset [1], tim2dset [2]
 HISTORY:
 	HSH, KO, written May 29, 1992
	MDM (9-Jun-92) Modified to output sub-frame number (=2*dataset #)
			Made head_str and and head_int two element arrays


WBS_DECOMP $SSW/yohkoh/ucon/idl/hudson/wbs_decomp.pro
[Previous] [Next]
 NAME:
	WBS_DECOMP
 PURPOSE:
 	Restore HXT and WBS data from the 8-bit telemetry format to 
	the full 12 bits. Same as HXT_DECOMP
 HISTORY:
	HSH, renamed 16-Apr-93


WBS_STRUCT $SSW/yohkoh/gen/idl/ref_access/wbs_struct.pro
[Previous] [Next]
       NAME:
               WBS_STRUCT
       PURPOSE:
               Define the following WBS specific database structures
                       * WBS_QS_Instr_Rec         
                       * WBS_QS_Offset_Rec        
                       * WBS_QS_Del_Rec           
                       * WBS_QS_Conv1_Rec         
                       * WBS_QS_Conv2_Rec         
                       * WBS_Index_Rec            
                       * WBS_DHK_Data_Rec         
                       * WBS_PC_Data_Rec          
                       * WBS_PH_Data_Rec          
                       * WBS_RoadMap_Rec          

       CALLING SEQUENCE:
               WBS_STRUCT
 CALLED BY:
	rd_roadmap [1]
       HISTORY:
               written by Mons Morrison, Fall 90.


WBS_TVEC $SSW/yohkoh/ucon/idl/bentley/wbs_tvec.pro
[Previous] [Next]
 NAME:
	WBS_TVEC
 PURPOSE:
	Creates corrected vector of WBS times
 CALLING SEQUENCE:  
	times = wbs_tvec(index)
 INPUTS:
	index	stabdard yohkoh index record
 OPTIONAL INPUTS:

 OUTPUTS:
	times	structure of times corrected for timing "errors" in telemetry
 OPTIONAL OUTPUTS:

 CALLS: ***
	ALL_VALS [1], ALL_VALS [2], ANYTIM2MSV, MSV2INTS, gt_dp_mode [1], gt_dp_mode [2]
	gt_dp_rate [1], gt_dp_rate [2]
 CALLED BY:
	OBS_PLOT
 RESTRICTIONS:

 PROCEDURE:
	Subtracts 2 secs in high bitrate and 9 secs in medium bitrate
 MODIFICATION HISTORY:
	RDB  08-Aug-94	Written


WBSA [1] $SSW/yohkoh/bcs/idl/atest/wbsa.pro
[Previous] [Next]
 NAME:
             WBSA
 PURPOSE:
             to provide widget interface to MKBSA/MKBSA programs
 CATEGORY: 
             widgets 
 CALLING SEQUENCE:
             WBSA,BSA_CON
 OUTPUTS:
             BSA_CON - Control structure to guide MKBSC
 CALLS: ***
	WBSA_EVENT, XMANAGER, XMENU [1], XMENU [2], XREGISTERED, mk_bsa_ans
 CALLED BY:
	GET_BSA_ANS [1], GET_BSA_ANS [2]
 RESTRICTIONS: 
             needs X-windows 
 MODIFICATION HISTORY:
             written Dec'92 by DMZ (ARC) 


WBSA [2] $SSW/yohkoh/bcs/idl/bsc/wbsa.pro
[Previous] [Next]
 NAME:
             WBSA
 PURPOSE:
             to provide widget interface to MKBSA/MKBSA programs
 CATEGORY: 
             widgets 
 CALLING SEQUENCE:
             WBSA,BSA_CON
 OUTPUTS:
             BSA_CON - Control structure to guide MKBSC
 CALLS: ***
	WBSA_EVENT, XMANAGER, XMENU [1], XMENU [2], XREGISTERED, mk_bsa_ans
 CALLED BY:
	GET_BSA_ANS [1], GET_BSA_ANS [2]
 RESTRICTIONS: 
             needs X-windows 
 MODIFICATION HISTORY:
             written Dec'92 by DMZ (ARC) 


WBSC [1] $SSW/yohkoh/bcs/idl/atest/wbsc.pro
[Previous] [Next]
 NAME:
             WBSC
 PURPOSE:
             to provide widget interface to Yohkoh BSC data
 CALLING SEQUENCE:
             WBSC
 INPUTS:
             bsc_index = BSC index structure
             bsc_data  = BSC data structure
 CALLS: ***
	ATIME [1], ATIME [2], BSC_CHECK [1], BSC_CHECK [2], CLEANPLOT [1], CLEANPLOT [2]
	CLEANPLOT [3], CW_FSLIDER, GT_BSC_CHAN [1], GT_BSC_CHAN [2], GT_BSC_CRATE, SEL_BSC
	SET_UTLABEL, WBSC_FIT, WBSC_FPAR, WBSC_LTC, WBSC_PLOT_LTC, WBSC_SPC, WBSC_WRITE_ASC
	WR_ASC, XMANAGER, XMENU [1], XMENU [2], XPDMENU, XREGISTERED, chktag, clearplot [1]
	clearplot [2], gt_day [1], gt_day [2], gt_time [1], gt_time [2], linecolors [1]
	linecolors [2], plotltc [1], plotltc [2], set_hard
 CALLED BY:
	PLOT_BSC [1], PLOT_BSC [2]
 RESTRICTIONS: 
             needs X-windows 
 MODIFICATION HISTORY:
             Jan'93, written, DMZ (ARC) 
             21-Oct-93, modularized, DMZ (ARC)


WBSC [2] $SSW/yohkoh/bcs/idl/bsc/wbsc.pro
[Previous] [Next]
 NAME:
             WBSC
 PURPOSE:
             to provide widget interface to Yohkoh BSC data
 CALLING SEQUENCE:
             WBSC
 INPUTS:
             bsc_index = BSC index structure
             bsc_data  = BSC data structure
 CALLS: ***
	ATIME [1], ATIME [2], BSC_CHECK [1], BSC_CHECK [2], CLEANPLOT [1], CLEANPLOT [2]
	CLEANPLOT [3], CW_FSLIDER, GT_BSC_CHAN [1], GT_BSC_CHAN [2], GT_BSC_CRATE, SEL_BSC
	SET_UTLABEL, WBSC_FIT, WBSC_FPAR, WBSC_LTC, WBSC_PLOT_LTC, WBSC_SPC, WBSC_WRITE_ASC
	WR_ASC, XMANAGER, XMENU [1], XMENU [2], XPDMENU, XREGISTERED, chktag, clearplot [1]
	clearplot [2], gt_day [1], gt_day [2], gt_time [1], gt_time [2], linecolors [1]
	linecolors [2], plotltc [1], plotltc [2], set_hard
 CALLED BY:
	PLOT_BSC [1], PLOT_BSC [2]
 RESTRICTIONS: 
             needs X-windows 
 MODIFICATION HISTORY:
             Jan'93, written, DMZ (ARC) 
             21-Oct-93, modularized, DMZ (ARC)


WBSC_FIT_EV [1] $SSW/yohkoh/bcs/idl/atest/wbsc_fit_ev.pro
[Previous] [Next]
 NAME:
             WBSC_FIT_EV
 PURPOSE:
             event handler for WBSC fit spectrum widget
 CALLS: ***
	TEST_OPEN, WBSC_PLOT_FIT, XMANAGER, get_bsc_wtype
 MODIFICATION HISTORY:
             DMZ (ARC) - written Jan'93


WBSC_FIT_EV [2] $SSW/yohkoh/bcs/idl/bsc/wbsc_fit_ev.pro
[Previous] [Next]
 NAME:
             WBSC_FIT_EV
 PURPOSE:
             event handler for WBSC fit spectrum widget
 CALLS: ***
	TEST_OPEN, WBSC_PLOT_FIT, XMANAGER, get_bsc_wtype
 MODIFICATION HISTORY:
             DMZ (ARC) - written Jan'93


WBSC_FPAR_EV [1] $SSW/yohkoh/bcs/idl/atest/wbsc_fpar_ev.pro
[Previous] [Next]
 NAME:
             WBSC_FPAR_EV
 PURPOSE:
             event handler for WBSC fit parameter widget
 CALLS: ***
	ATIME [1], ATIME [2], SET_UTLABEL, TEST_OPEN, WBSC_PLOT_FPAR, get_bsc_wtype
	plotltc [1], plotltc [2], set_hard
 MODIFICATION HISTORY:
             DMZ (ARC) - written Nov'93


WBSC_FPAR_EV [2] $SSW/yohkoh/bcs/idl/bsc/wbsc_fpar_ev.pro
[Previous] [Next]
 NAME:
             WBSC_FPAR_EV
 PURPOSE:
             event handler for WBSC fit parameter widget
 CALLS: ***
	ATIME [1], ATIME [2], SET_UTLABEL, TEST_OPEN, WBSC_PLOT_FPAR, get_bsc_wtype
	plotltc [1], plotltc [2], set_hard
 MODIFICATION HISTORY:
             DMZ (ARC) - written Nov'93


WBSC_LTC_EV [1] $SSW/yohkoh/bcs/idl/atest/wbsc_ltc_ev.pro
[Previous] [Next]
 NAME:
             WBSC_LTC_EV
 PURPOSE:
             event handler for WBSC lightcurve widget
 CALLS: ***
	BCS_SPEC_PLOT, CHKLOG [1], CHKLOG [2], CLEAR_UTPLOT [1], CLEAR_UTPLOT [2]
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], GT_BSC_CHAN [1], GT_BSC_CHAN [2]
	LZPLOT, MK_TEMP_FILE, SEL_BSC, TEST_OPEN, WBSC_GET_SPC, WBSC_LTC_RANGE
	WBSC_PLOT_FIT, WBSC_PLOT_LTC, WBSC_PLOT_SPC, WBSC_WRITE_ASC, WBSC_WRITE_EV
	XDISPLAYFILE [1], XDISPLAYFILE [2], XMANAGER, binup, concat_dir [4], fmt_tim [1]
	fmt_tim [2], get_bsc_anno, get_bsc_wtype, gt_time [1], gt_time [2]
 MODIFICATION HISTORY:
             DMZ (ARC) - written Jan'93


WBSC_LTC_EV [2] $SSW/yohkoh/bcs/idl/bsc/wbsc_ltc_ev.pro
[Previous] [Next]
 NAME:
             WBSC_LTC_EV
 PURPOSE:
             event handler for WBSC lightcurve widget
 CALLS: ***
	BCS_SPEC_PLOT, CHKLOG [1], CHKLOG [2], CLEAR_UTPLOT [1], CLEAR_UTPLOT [2]
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], GT_BSC_CHAN [1], GT_BSC_CHAN [2]
	LZPLOT, MK_TEMP_FILE, SEL_BSC, TEST_OPEN, WBSC_GET_SPC, WBSC_LTC_RANGE
	WBSC_PLOT_FIT, WBSC_PLOT_LTC, WBSC_PLOT_SPC, WBSC_WRITE_ASC, WBSC_WRITE_EV
	XDISPLAYFILE [1], XDISPLAYFILE [2], XMANAGER, binup, concat_dir [4], fmt_tim [1]
	fmt_tim [2], get_bsc_anno, get_bsc_wtype, gt_time [1], gt_time [2]
 MODIFICATION HISTORY:
             DMZ (ARC) - written Jan'93


WBSC_SPC_EV [1] $SSW/yohkoh/bcs/idl/atest/wbsc_spc_ev.pro
[Previous] [Next]
 NAME:
             WBSC_SPC_EV
 PURPOSE:
             event handler for WBSC spectrum widget
 CALLS: ***
	BCS_SPEC_PLOT, DELVARX [1], DELVARX [2], DELVARX [3], DELVARX [4], FIT_SPEC
	GT_BSC_BINCAL [1], GT_BSC_BINCAL [2], LZPLOT, MK_TEMP_FILE, WBSC_FIT_SPC
	WBSC_PLOT_SPC, WBSC_SPC_RANGE, WBSC_SYNTH_SPC, WBSC_WRITE_ASC, WBSC_WRITE_EV
	delvarx [5], fit_bsc, get_bsc_anno, get_bsc_wtype
 MODIFICATION HISTORY:
             DMZ (ARC) - written Jan'93


WBSC_SPC_EV [2] $SSW/yohkoh/bcs/idl/bsc/wbsc_spc_ev.pro
[Previous] [Next]
 NAME:
             WBSC_SPC_EV
 PURPOSE:
             event handler for WBSC spectrum widget
 CALLS: ***
	BCS_SPEC_PLOT, DELVARX [1], DELVARX [2], DELVARX [3], DELVARX [4], FIT_SPEC
	GT_BSC_BINCAL [1], GT_BSC_BINCAL [2], LZPLOT, MK_TEMP_FILE, WBSC_FIT_SPC
	WBSC_PLOT_SPC, WBSC_SPC_RANGE, WBSC_SYNTH_SPC, WBSC_WRITE_ASC, WBSC_WRITE_EV
	delvarx [5], fit_bsc, get_bsc_anno, get_bsc_wtype
 MODIFICATION HISTORY:
             DMZ (ARC) - written Jan'93


wconroi $SSW/yohkoh/ucon/idl/linford/wconroi2.pro
[Previous] [Next]
 NAME:
	wconroi
 PURPOSE:
	Define a contoured region-of-interest of an image
	using either a slider widget or cursor/mouse.

 CATEGORY:
	Image processing.

 CALLING SEQUENCE:
	Result = conroi( data(*,*,n), [Xverts, Yverts, zoom=4, wid=wid],
		etop=etop)

 INPUTS:
	Data:  2-dimensional image matrix.
       etop:  list of pointers to the widgets

 KEYWORD PARAMETERS:
	ZOOM:	Zoom factor.  If omitted, 1 is assumed.

	NOREGION:  Inhibits the return of the pixel subscripts.
	
	wid:	window id/number used for display. 
		(default is to use the current window)

	ret1d:	return vector is a linear list of subscripts
 OUTPUTS:
	This function returns a vector containing the subscripts of pixels 
	inside the CONTOURED region.  Note that these are 2dim lists by
	default, the 2nd dim covers the number of contours.  To force all
	contour subscripts into a  "linear" list of subscripts, use /ret1d.
	Note: Subscripts returned only, no "X, Y" pairs.  
	See the EXAMPLE below.

	Side effect: The lowest bit in which the write mask is enabled
	is changed.

 OPTIONAL OUTPUTS:
	Xverts, Yverts:  Optional output parameters that contain
	the contoured path enclosing the region.  Setting the keyword
	NOREGION inhibits the return of the pixel subscripts.

 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], WCONROI2, WDEF [1], WDEF [2]
	concat_dir [4], rd_conroi, tv_coors
 SIDE EFFECTS:
	For this implementation, XOR graphics is used.

 PROCEDURE:
	A message is printed that describes the effect of the three mouse 
	buttons.  The operator marks the contour the region using the 
	mouse.

	When the operator is finished, the region is outlined and, 
	the polyfillv function is used to compute the returned subscripts 
	within the region.

 EXAMPLE:
	This example shows how you can "cut out" a region of an image using 
	conroi and then display that region.  First, create an image cube
	via test_rd, align the data cube with rd_ar, select an image of 
	interest via stepper ...

	Now use CONROI to contour any region of the image that you want.  
	Enter for the ith image:

		CUTOUT = wconroi( data(*,*,i), zoom=4)

	Move the mouse cursor over the image.  Mark a contour with the left 
	button.  To adjust the contour level "up" or "down" click on the
	"up"/"down" boxes.  To change the increment, click on the "inc" box
	and adjust the value by clicking in the "up"/"down" boxes.  To return
	to contour adjust mode click the "levels" box.  To EXIT the press the 
	right button.

	Make a new, empty array the same size as the previous image. Enter:

		NEW = BYTARR(64, 64)

	CUTOUT contains a list of the selected pixels.  Put only the selected
	pixels from the original image D into the image NEW.  Enter:

		NEW(CUTOUT) = D(CUTOUT)

	Display the new image:

		TV, NEW

 MODIFICATION HISTORY:
		written July, 93 by GAL (from conroi.pro).
		bug for mult. contours fixed 26-Oct-93


wd $SSW/yohkoh/ucon/idl/foley/wd.pro
[Previous] [Next]
 NAME:
  wd.pro
 PURPOSE
  Blows away five of those X-windows.

 CALLING SEQUENCE
  none
 INPUT
  none
 OUTPUT INPUT
  num :  number of xwindows to delete

 OPTIONAL OUTPUT
  none
 OPTIONAL KEYWORD INPUT
  none
 RESTRICTION
  none

 HISTORY
  Written CAF 5 MAY 96 : caf@mssl.ucl.ac.uk


wdefbox [1] $SSW/yohkoh/ucon/idl/linford/defbox.pro
[Previous] [Next]
	NAME: wdefbox
	PURPOSE: Define a rectangular ROI with two mouse clicks.
	CALLING SEQUENCE:
		a = wdefbox(nx, ny, zoom=zoom, [boxout=boxout]) or
		a = wdefbox(nx, ny, zoom=zoom, /quiet, /recursive, etop=etop)
		        (second usage is for widget mode)
	Check code for usage of formal parameters

 CALLED BY:
	wdefroi [1], wdefroi [2]
	History: written 2-Jul-93, gal
	-----------------------------------------------------------------


wdefbox [2] $SSW/yohkoh/ucon/idl/linford/wdefbox.pro
[Previous] [Next]
	NAME: wdefbox
	PURPOSE: Define a rectangular ROI with two mouse clicks.
	CALLING SEQUENCE:
		a = wdefbox(nx, ny, xverts, yverts, zoom=zoom, 
						[boxout=boxout]) or
		(returns after box is defined withOUT right button click)
		a = wdefbox(nx, ny, xverts, yverts, zoom=zoom, 
					/quiet, /recursive, etop=etop)
		        (second usage is for widget mode)
		(returns after box is defined WITH right button click)

	INPUT:
		xs	x-size of image 
		ys	y-size of image
		zoom	optional zoom factor of image (defaults to 1)
		recur*	allows user to reselect box until right mouse
			button is depressed.
		
	RETURNS:
		list 	of indices contained within the selected box.

	OPTIONAL OUTPUT:
		boxout	matrix with the lower-left and upper-right
			corner coordinates.
		xverts 	x-coordinates of box
		yverts	y-coordinates of box

 CALLED BY:
	wdefroi [1], wdefroi [2]
	History: written 2-Jul-93, gal
		16-Aug-93, gal, added xverts and yverts as optional output.
	-----------------------------------------------------------------


wdefroi [2] $SSW/yohkoh/gen/idl/util/wdefroi_event.pro
[Previous] [Next]
	Name: wdefroi
	Purpose: event driver for wdefroi.

 CALLS: ***
	DEFROI [1], DEFROI [2], UTPLOT [1], UTPLOT [2], UTPLOT [3], UTPLOT [4], UTPLOT [5]
	UTPLOT [6], WCONROI2, WDEF [1], WDEF [2], WDEFROI_EVENT, XLOADCT [1], XLOADCT [2]
	XLOADCT [3], wdefbox [1], wdefbox [2]
 CALLED BY:
	TRACE_CUBE_POINTING, TRACE_MDI_ALIGN, azi_calc, azimuth_avg, go_teem [1]
	go_teem [2], go_teem_t, radial_avg, scat_avg, sector_avg, setpts_roi
	History: written July-93, gal
		last mods 11-Aug-93
		change reset from tv to tvscl, 24-Oct. 93
		changed select tv to tvscl, 25-Oct. 93
		updated call to wconroi2, 26-Oct-93, gal
		updated call to wconroi2, for wherefill switch, 31-May-94,
		gal.


wdefroi [3] $SSW/yohkoh/gen/idl/ys_util/wdefroi.pro
[Previous] [Next]
	NAME: wdefroi

	Purpose: Define a region of interest via the outline of a
		rectangle, polygon or intensity contour and return 
		the indices or SUB-Image that contains the region.

	Calling Sequence:
		list = wdefroi( data, xverts, yverts, [zoom=zoom, 
				sub=sub, image=image
				time=time, lc=lc, logscale=logscale,
                               wherefill=wherefill])
	Where,	
	
	INPUT:
		data		is the image for which an ROI is wanted.
		xverts		Optional output of x-coordin. outline region
		yverts		Optional output of y-coordin. outline region
		zoom		is the zoom factor (default is 1).
		sub		is the image index number to use for ROI
				selection if data is 3-dimen.
		image		if set will return IMAGE(S) instead of indices
		time		list of times which corresponds with data
				a Yohkoh index record is also ok.
		lc		lc activiate light curve option ...this uses
				LOTS of MEMORY
		logscale	if set will log scale the data for display.
		wherefill	if set will use where instead of ployfillv
				to define the indices of enclosed region.
				(wherefill works better than ployfillv for
				images with a very small number of pixels)

	OUTPUT:
		list 		is the returned list of selected indices of
				the input image OR 
				a regular sub-image(s) that contains the 
				region if "/image" switch is used.

 CALLS: ***
	MAKE_STR [1], MAKE_STR [2], STEPPER [1], STEPPER [2], STEPPER [3], STEPPER [4]
	STEPPER [5], STEPPER [6], STEPPER [7], XMANAGER, XMENU [1], XMENU [2]
	anytim2ints [1], anytim2ints [2], idx2img
 CALLED BY:
	TRACE_CUBE_POINTING, TRACE_MDI_ALIGN, azi_calc, azimuth_avg, go_teem [1]
	go_teem [2], go_teem_t, radial_avg, scat_avg, sector_avg, setpts_roi
	History:
		written by GAL, July-93 
		24-Jul-93, added xverts and yverts
		25-Jul-93, added image keyword option to return sub-image.
		24-Oct-93, added tv command to display images if stepper
			is not involked... and changed scale to logscale
			to be more descriptive of the action.
		26-Oct-93, minor mod to ensure bytscl of displayed images.
		31-May-94, add wherefill keyword
	----------------------------------------------------------------


wdefroi [4] $SSW/yohkoh/ucon/idl/nitta/wdefroi_nn.pro
[Previous] [Next]
	NAME: wdefroi

	Purpose: Define a region of interest via the outline of a
		rectangle, polygon or intensity contour and return 
		the indices or SUB-Image that contains the region.

	Calling Sequence:
		list = wdefroi( data, xverts, yverts, [zoom=zoom, 
				sub=sub, image=image
				time=time, lc=lc, logscale=logscale,
                               wherefill=wherefill])
	Where,	
	
	INPUT:
		data		is the image for which an ROI is wanted.
		xverts		Optional output of x-coordin. outline region
		yverts		Optional output of y-coordin. outline region
		zoom		is the zoom factor (default is 1).
		sub		is the image index number to use for ROI
				selection if data is 3-dimen.
		image		if set will return IMAGE(S) instead of indices
		time		list of times which corresponds with data
				a Yohkoh index record is also ok.
		lc		lc activiate light curve option ...this uses
				LOTS of MEMORY
		logscale	if set will log scale the data for display.
		wherefill	if set will use where instead of ployfillv
				to define the indices of enclosed region.
				(wherefill works better than ployfillv for
				images with a very small number of pixels)
               area            regions previously selected

	OUTPUT:
		list 		is the returned list of selected indices of
				the input image OR 
				a regular sub-image(s) that contains the 
				region if "/image" switch is used.

 CALLS: ***
	MAKE_STR [1], MAKE_STR [2], PLOT_AREA_NN, STEPPER [1], STEPPER [2], STEPPER [3]
	STEPPER [4], STEPPER [5], STEPPER [6], STEPPER [7], WDEFROI_NN, XMANAGER, XMENU [1]
	XMENU [2], anytim2ints [1], anytim2ints [2], idx2img
 CALLED BY:
	TRACE_CUBE_POINTING, TRACE_MDI_ALIGN, azi_calc, azimuth_avg, go_teem [1]
	go_teem [2], go_teem_t, radial_avg, scat_avg, sector_avg, setpts_roi
	History:
		written by GAL, July-93 
		24-Jul-93, added xverts and yverts
		25-Jul-93, added image keyword option to return sub-image.
		24-Oct-93, added tv command to display images if stepper
			is not involked... and changed scale to logscale
			to be more descriptive of the action.
		26-Oct-93, minor mod to ensure bytscl of displayed images.
		31-May-94, add wherefill keyword
               14-Jan-95, add area keyword to display previously selected
	----------------------------------------------------------------


week_loop [2] $SSW/yohkoh/gen/idl/atest/week_loop.pro
[Previous] [Next]
NAME: 
	week_loop
PURPOSE:
	Given a start and end time, return a structure listing the
	year number and week number for all weeks between the times
INPUT:
	sttim - start time in any format
	entim - end time in any format
KEYWORD PARAMETERS:
	weekstr (output) - string of form YY_WW or YYYY_WW  
	year4digit (switch) - if set, out.year and weekstr are 4 digit
 CALLS: ***
	anytim [1], anytim [2], anytim [3], anytim [4], anytim [5], ex2dow [1], ex2dow [2]
	ex2week [1], ex2week [2], weeks_in_year [1], weeks_in_year [2]
 CALLED BY:
	BCS_24HR_PLOT [1], BCS_24HR_PLOT [3], BUILD_SSX, GET_SUBARR2, mk_orbit [1]
	mk_orbit [2], mk_sdcs, rd_sdl, rd_sld, rd_sls, rd_sot, rd_ssl, rd_sxa, rd_sxc, rd_sxl
	rd_week_file [2], sxl_analysis, weekid [2], ydb_exist [1], ydb_exist [2]
	ydb_exist [3], ydb_exist [4], yo_mkos1_dbase
HISTORY:
	Written 16-Apr-92 by M.Morrison
	08-Feb-1992 (MDM) Added code to back up a week if the start time
			  is within 90 minutes of the first day of a week
       06-Apr-1999 (SLF) Made it Y2K able via /year4digit
       		  Added WEEKSTR output
       09-May-2000 (PGS) Standardized year format in four places.
	06-Mar-2001 (GLS) Completely re-written with new logic.
TODO:
	- Check with Sam about whether Mon's logic could be improved
	  to only include a previus week where actually necessary
	  (now it ALWAYS adds a week at the beginning if the start
	  time is within 100 minutes of the startof the week)
	- Vectorize the for loop, if possible
	- Make weeks_in_year work on times in any format and not only
	  years
	- Make year4digit the default, and use wid_vec as output string
	  name (removing weekstr)?


week_loop [3] $SSW/yohkoh/gen/idl/ref_access/week_loop.pro
[Previous] [Next]
NAME: 
	week_loop
PURPOSE:
	Given a start and end time, return a structure listing the
	year number and week number for all weeks between the times
INPUT:
	sttim	- start time in any format
	entim	- end time in any format
 CALLS: ***
	anytim [1], anytim [2], anytim [3], anytim [4], anytim [5], ex2dow [1], ex2dow [2]
	ex2week [1], ex2week [2], weeks_in_year [1], weeks_in_year [2]
 CALLED BY:
	BCS_24HR_PLOT [1], BCS_24HR_PLOT [3], BUILD_SSX, GET_SUBARR2, mk_orbit [1]
	mk_orbit [2], mk_sdcs, rd_sdl, rd_sld, rd_sls, rd_sot, rd_ssl, rd_sxa, rd_sxc, rd_sxl
	rd_week_file [2], sxl_analysis, weekid [2], ydb_exist [1], ydb_exist [2]
	ydb_exist [3], ydb_exist [4], yo_mkos1_dbase
HISTORY:
	Written 16-Apr-92 by M.Morrison
	 8-Feb-92 (MDM) Added code to back up a week if the start time
			is within 90 minutes of the first day of a week


week_totalspro MAIN [1] $SSW/yohkoh/gen/idl/atest/week_totals.pro
[Previous] [Next]
NAME:	week_totals.pro (MAIN)
PURPOSE: read 8mm archive tape directory files and summarize the
	file/tape sizes.

HISTORY:
	Ver 2.0 (11-Jan-93) - Modification to skip the first fileid
			      since that is the week ID entry
	Ver 2.1 (14-Jun-95) - GAL, modes to true Mb and added doc.
			      header.
       modified mb size (12-Jan-98) PGS


week_totalspro MAIN [2] $SSW/yohkoh/gen/idl/reformat/week_totals.pro
[Previous] [Next]
NAME:	week_totals.pro (MAIN)
PURPOSE: read 8mm archive tape directory files and summarize the
	file/tape sizes.

HISTORY:
	Ver 2.0 (11-Jan-93) - Modification to skip the first fileid
			      since that is the week ID entry
	Ver 2.1 (14-Jun-95) - GAL, modes to true Mb and added doc.
				header.


weekfiles $SSW/yohkoh/gen/idl/dbase/weekfiles.pro
[Previous] [Next]
   Name: weekfiles

   Purpose: return file names of weekly data base files

   Input Parameters (Optional):
      start - start time of interest (default = earliest)
      stop  - stop time of interest (default = latest)

   Keyword Parameters:
      obs, pnt, xbd, xad, fem - prefix for desired weekly file
				 assume one and only one set

   Disclaimer - since I tried to make use of alot of existing routines,
		 some loss of efficiency is encountered - if you want
		 speed, rewrite it and let me know where it is. 

   History - slf, 24-feb-1992

 CALLS:
 CALLED BY
	go_mk_cd, pfi_dominant, prep_week [1], prep_week [2], rd_xbd, tap_wrt_chk


weekid [3] $SSW/yohkoh/gen/idl/dbase/weekid.pro
[Previous] [Next]
   Name: weekid

   Purpose: return expanded file ids for weekly files in common area 
	     (provide single point maint for weekly prefix definitions)

   Input Parameters:
	fileid = xxxyy_wwn (string) - standard weekly file name
 		 if xxx is included, only that prefix is checked
   Output:
	function returns string scaler or array
	default is latest version only (scaler)
	
   Optional Keyword Parameters:
	all - if set, all prefixes are checked
	xbd,xad,pnt,fem,obs - prefixes to check (mutally exclusive)
	indir	- if set, look at that directory instead of the
		  "standard" directory.
	gt_pre - if set, returns weekid prefixes only
	gt_distpre - if set, returns weekid prefixes for distributed
		     (tar sets) only
       vnum - version number (limit search to only these versions)

   Output Parameters:
	ver - highest existing version (integer) - 00 if no such file

 CALLS: ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], CONCAT_DIR [1], CONCAT_DIR [2]
	CONCAT_DIR [3], break_file [4], concat_dir [4], str_replace [1], str_replace [2]
 CALLED BY:
	cktapdir, def_save, gen_file_id [1], gen_file_id [2], gen_fn [1], gen_fn [2]
	get_afile_size [1], get_afile_size [2], rd_week_file [1], rd_week_file [2]
	rd_week_file [3], rd_week_file [4], weekfiles, ydb_exist [2], yo_arch_size
   Modification History:
	Written: slf, 19-feb-92
		 slf,  8-mar-92 	added gt_pre for single pt maint
		 mdm, 20-May-92		Added "indir" option
		 mdm,  9-Jun-92		Removed unix specific "/" code 
					Used wildcard "*.*" instead of "*"
	         slf, 22-Jun-92		Added nar,evn,gev 
		 slf, 20-Oct-92		Added gxt
		 slf, 24-Nov-92		Added ssl, sot
		 slf,  6-apr-93		Added prefix and vnum keywords
                slf, 19-aug-93         replaced recursive segment


weekid2ex [3] $SSW/yohkoh/gen/galileo/idl/lmsal/weekid2ex.pro
[Previous] [Next]
 NAME:
   weekid2ex
 PURPOSE:
   Convert Week number to external time
 CALLING SEQUENCE:
   Time_ex = weekid2ex('94_04a')	; Time range of week 4 of 1994
   Time_ex = weekid2ex(4)		; Week 4 of current year
   Time_ex = weekid2ex(4,year=93)	; Week 4 of 1993
   Time_ex = weekid2ex('94_04a', t1, t2 ) ; t1/t2 = first/last day of week
   Time_ex = weekid2ex('94_04a', t1, t2, ndays )
 INPUT:
   week_id	= Yohkoh Week ID (string) - may be a vector
		= or week number (integer)
 OPTIONAL OUTPUTS:
   t1, t2	= First/Last day of specified week(s) (string-type)
   ndays	= Number of days in the week
 OPTIONAL KEYWORD INPUTS:
   year	= Year number in case week_id is an integer
 OPTIONAL KEYWORD OUTPUTS:
   week_id_fmt	= String version of week ID
 CALLS: ***
	anytim2ex [1], anytim2ex [2], anytim2ints [1], anytim2ints [2]
	anytim2weekid [1], anytim2weekid [2], week2ex [1], week2ex [2]
 CALLED BY:
	mk_sdm, pr_week2tim [1], pr_week2tim [2]
 PROCEDURE:
   Calls anytime2ex, ex2week, week2ex
   Short weeks (first and last week of the year) are flagged with a "*".
 MODIFICATION HISTORY:
   22-jan-94, J. R. Lemen, Written
   25-apr-06, L. W. Acton, Changed week # test to 1-54 to handle year 2000.
	Later:		Oops, missed one test, fixed.


weeks_in_year [2] $SSW/yohkoh/gen/idl/atest/weeks_in_year.pro
[Previous] [Next]
NAME: 
	weeks_in_year
PURPOSE:
	Return the weeks in the calendar year or years corresponding to
	to an input time or times.
INPUT:
	input - may be:
		 - scalar or vector of years in any numerical format
		 - scalar or vector of times in any format
 CALLS: ***
	UTC2DOW, anytim [1], anytim [2], anytim [3], anytim [4], anytim [5], data_chk [1]
	data_chk [2]
 CALLED BY:
	week_loop [1], week_loop [2], week_loop [3]
HISTORY:
	06-Mar-2001 - GLS
       28-Dec-2002 - Zarro (EER/GSFC), changed SIZE to DATA_CHK for backwards
                     compatibility


WERE_THERE_FALSE_FLARES $SSW/yohkoh/ucon/idl/hudson/were_there_false_flares.pro
[Previous] [Next]
 NAME:
     WERE_THERE_FALSE_FLARES
 PURPOSE:
     identify in a roadmap variable if there were flare mode data
 CATEGORY:
 CALLING SEQUENCE:
     .run were_there_false_flares
 INPUTS:
     need to have roadmap in the session
 OPTIONAL (KEYWORD) INPUT PARAMETERS:
 OUTPUTS:
 COMMON BLOCKS:
 SIDE EFFECTS:
 RESTRICTIONS:
 MODIFICATION HISTORY:
     HSH, written with a Boolean boost from SF, 23-nov-94


wfile $SSW/yohkoh/ucon/idl/pike/wfile.pro
[Previous] [Next]

  Procedure to inform where (which tape and which data file) a specified
  event is likely to be.

  Input:
           date         Date and time of event. 
                        Formats accepted are the usual 
                        1) Vax-type date/time  (17-mar-92 17:23)
                        2) 7-element time array (hh mm ss msec dd mm yy)
                        3) File id format (920412.0123)

  Keyword: quiet        if set, do not echo results to terminal

  Output:
           t_name        name of the archive tape
           f_name        file name within that tape (or on disk)

  Use:
          IDL>  wfile,'12-Mar-92 15:34',t_name,f_name
          IDL>  wfile,'920423.1234'

  	CDP 	April 92
	RDB	20-Jun-92	Capitalized $DIR_GEN_XDB for Unix
				Added use on CONCAT_DIR
       CDP     17-Sept-92      Fix bug for week numbers < 10 and for files
                               before the beginning of the first file of the 
                               week. 
       CDP     28-Jan-93       Cater for the new tape versions .02/.03 etc
                               by picking the last (and latest version) for
                               searching.
                               Added quiet keyword.

 CALLS:
 CALLED BY
	SELECT_24HR


wfilpck $SSW/yohkoh/ucon/idl/linford/wfilpck.pro
[Previous] [Next]
	NAME: wfilpck
	PURPOSE: Allow user to pick filters for plasma parameter study.

	Calling Sequence:
		wfilpck, index, thicks, thins, [interp_thin]
	
	Input:
		index	data-index records
	Output:
		thicks	list of indices for selected thick filter
		thins	list of indices for selected thin filter
	Optional Output:
		interp_thin	if present will allow user to select an 
			interpolation mode via the widget and return
			the selected interpolation mode:
			0	interpolate all data to times of
				thin filtered data.
			1	interpolate all data to times of
				thick filtered data.
		       -1	no interpolation 

 CALLS: ***
	GET_INFO2, MAKE_STR [1], MAKE_STR [2], UNIQ [1], UNIQ [2], UNIQ [3], XMANAGER
	XMENU [1], XMENU [2], gt_filtb
 CALLED BY:
	go_teem [1], go_teem [2], go_teem_nn, go_teem_t
	History: written by gal 24-Aug-93
		mod 15-sept. for adding interpolation selection
		15-NOV-94, GAL, Modifed to row widget. With, list
		on left and buttons on the right. 


wfilpck_event $SSW/yohkoh/ucon/idl/linford/wfilpck_event.pro
[Previous] [Next]
	NAME: wfilpck_event

	PURPOSE: event driver for wfilpck.
	
	History: written 26-Aug-93


WFITS $SSW/yohkoh/gen/idl/gbo/wfits.pro
[Previous] [Next]
 NAME:
        WFITS
 PURPOSE:
        Writes an array into a standard FITS file on the disk.
        A simple FITS header is created automatically.
 CATEGORY:
        Input/Output
 CALLING SEQUENCE:
        wfits, array, filename
 INPUTS:
        array = data array.
        filename = string containing the file name.
 OPTIONAL (KEYWORD) INPUT PARAMETERS:
        index = nonnegative integer. If this parameter is present, a period
              and the index number are appended to the filename (e.g., '.34').
              This option makes handling of data in the MCCD file naming
              convention easier.
        date_obs = string. A FITS keyword parameter "DATE_OBS= 'string'" is
                   added to the header.
        time_obs = string. A FITS keyword parameter "TIME_OBS= 'string'" is
                   added to the header.
        history = string. A FITS keyword parameter "HISTORY string" is added
                   to the header.
        comment = string. A FITS keyword parameter "COMMENT string" is added
                   to the header.
 OUTPUTS:
        No explicit outputs.
 COMMON BLOCKS:
        None.
 SIDE EFFECTS:
        A file is created, or overwritten.
 RESTRICTIONS:
        If array is not of type byte, integer, or long, then a conversion
        to type integer is done. No scaling is made beforehand, so significant
        loss of information is possible.
        Only a very simple FITS header can be created.
 MODIFICATION HISTORY:
        JPW, Nov, 1989.


where_change [2] $SSW/yohkoh/gen/idl/util/where_change.pro
[Previous] [Next]
   Name: where_change

   Purpose: return subscripts of vector where (d<vector>/dx > magnitude

   Input Parameters:
      vector - vector to check
      magnitude - size of change to flag

   Keyword Parameters:
      step - if set, only flag single step changes > magnitude 
                     (default includes gradual changes)

 CALLS: ***
	deriv_arr [1], deriv_arr [2], tbeep [1], tbeep [2], tbeep [3]
   History:
      15-mar-1995 (SLF) - simplify pointing seperation code


WHICH_FILT $SSW/yohkoh/ucon/idl/hudson/which_filt.pro
[Previous] [Next]
 NAME:
     WHICH_FILT
 PURPOSE:
     determine which H res filters exist in a data set. To 
       run this if you have infil = <filespec>, the easy
       way is to do rd_roadmap,infil,roadmap first
 CATEGORY:
     Yohkoh
 CALLING SEQUENCE:
     which_filt, roadmap 
 INPUTS:
     index or roadmap structure from SXT
 OPTIONAL (KEYWORD) INPUT PARAMETERS:
 OUTPUTS:
     prints to screen
 CALLS: ***
	HH_DELETE
 COMMON BLOCKS:
 SIDE EFFECTS:
 RESTRICTIONS:
 MODIFICATION HISTORY:
     HSH written 19 Dec 1994
     HSH touched up a bit 30 Dec 1994


width_1d $SSW/yohkoh/ucon/idl/mctiernan/width_1d.pro
[Previous] [Next]
 NAME:
       width_1d
 CALLING SEQUENCE:
       w = width_1d(f, x, fmax=fmax, xmax=xmax, oneover_e=oneover_e, expfac=expfac, $
                    fout=fout, xout=xout, spline=spline, frac=frac)
 PURPOSE:
       the full width at half-max (or 1/e) of an array
 INPUT:
       f = a vector
       x = the grid at which you have values for f
           if not passed in, x=findgen(n_elements(f)) is used
 OUTPUT:
       w = full width at half-max (or 1/e) of f
 KEYWORDS:
       fmax=maximum of f, output
       xmax=x value for fmax, output
       oneover_e=if set, use 1/e width instead of 1/2
       expfac=expansion factor for x-grid, default is 100
              the width is found by interpolating to a finer grid
              and using a where fn, to find all of the pts
              greater than fmax/2 on the fine grid, so expfac
              is a measure of the resolution of the answer,
              if the x-grid is intgers, the answer has .01
              accuracy.
       spline=if set, use spline interpolation to do this
       fout=values of f used for the calculation, given at
       xout=the fine grid used for the interpolation.
       frac=fraction used to determine width, default is
            0.5, if e is set, this will not be used
 CALLS: ***
	DSPLINE, interp1d [1], interp1d [2], interp1d [3]
 CALLED BY:
	width_2d
 HISTORY:
       18-feb-95, jmm


width_2d $SSW/yohkoh/ucon/idl/mctiernan/width_2d.pro
[Previous] [Next]
 NAME:
       width_2d
 CALLING SEQUENCE:
       w = width_2d(a, x, y, amax=amax, xymax=xymax, oneover_e=oneover_e, expfac=expfac, $
                    spline=spline, frac=frac)
 PURPOSE:
       the full width at half-max (or 1/e) of a 2d array, in both directions
 INPUT:
       a = an array
       x, y = the grid at which you have values for a
           if not passed in, x=findgen(n_elements(f(*,0))
           and y=findgen(n_elements(f(0,*)) are used
 OUTPUT:
       w = full width at half-max (or 1/e) of a, in (x,y)
 KEYWORDS:
       amax=maximum of a
       xymax= max 2d subscripts of amax
       oneover_e=if set, use 1/e width instead of 1/2
       expfac=expansion factor for grids, default is 100
              the width is found by interpolating to finer grids
              and using a where fn, to find all of the pts
              greater than amax/2 on the fine grid, so expfac
              is a measure of the resolution of the answer,
              if the x-grid is intgers, the answer has .01
              accuracy.
       spline=if set, use spline interpolation to do this
       frac=fraction used to determine width, default is
            0.5, if e is set, this will not be used
 CALLS: ***
	twod_subs, width_1d
 CALLED BY:
	find_ftpts
 HISTORY:
       18-feb-95, jmm


WIND_LOITER $SSW/yohkoh/ucon/idl/hudson/wind_loiter.pro
[Previous] [Next]
 NAME:
	WIND_LOITER
 PURPOSE
 	integrate travel time for Withbroe solar wind models near sun
	  and make a plot
 CALLING SEQUENCE
	main program

 IDL Version 3.0.0 (ultrix mipsel)
 Journal File for hudson@isass1.solar.isas.ac.jp
 Working directory: /usr/people/hudson
 Date: Mon Jan 24 09:59:52 1994


window_select $SSW/yohkoh/ucon/idl/suga/window_select.pro
[Previous] [Next]
  NAME:
       window_select
  PURPOSE:
       To allow a user to select the IDL window number
  CALLING SEQUENCE:
       window_select
  OPTIONAL INPUT KEYWORDS:
       title = a string 
       xs = window size for x-axis
       ys = window size for y-axis
 CALLS: ***
	wmenu_sel [1], wmenu_sel [2]
 CALLED BY:
	dataget_grs, pc_tplot_grs, pc_tplot_rbm, ph_eff_grs1, ph_eff_grs2, ph_pow_grs1
	ph_pow_grs2
  HISTORY:
       Written 15-apr-93 by T.Hiraoka


WITH_INT $SSW/yohkoh/ucon/idl/hudson/with_int.pro
[Previous] [Next]
 NAME:
     WITH_INT
 PURPOSE:
     Integrate Withbroe models to find radial variation of
       coronal brightness in soft X-rays. See WITHBROE for
       model details and a reference.
 CATEGORY:
     Yohkoh support
 CALLING SEQUENCE:
     flux = with_int(model_type, height, int_step=int_step)
 INPUTS:
     Type of Withbroe model (see WITHBROE); 3 => polar hole (min)
 OPTIONAL (KEYWORD) INPUT PARAMETERS:
     int_step is the number of steps per 10 R_sun in the integration,
       default is 100
     impact_par is the impact parameter in R_o (can be <1; default is
       .01, .02, ... 2.00
 OUTPUTS:
     structure containing the following tags:
       model_name
       height, the impact parameter in R_o
       thinal, the Al.1 counts
       dag,    the AlMg counts
       t_sky,  the Withbroe model temperature at r = impact parameter
       t_eff,  the effective temperature after integration to 10 R_o
       em_eff, the effective emission measure ditto
       dem,    the [t, em] distribution (fltarr(2, int_step))
 CALLS: ***
	SXT_TEEM [1], SXT_TEEM [2], WITHBROE, get_rb0p [1], get_rb0p [2], gt_pix_size
	sxt_flux [1], sxt_flux [2], sxt_flux [3]
 CALLED BY:
	SLOPE_TEMP
 COMMON BLOCKS:
 SIDE EFFECTS:
 RESTRICTIONS:
 ROUTINES CALLED:
	      WITHBROE, SXT_FLUX, GT_PIX_SIZE
 MODIFICATION HISTORY:
	      HSH Oct. 16, 1993
       HSH Mar. 30, 1994 added Dag to the output
       HSH Apr.  3, 1994 converted to a function and fixed bugs
       HSH Mar. 19, 2000 vectorized and structuralized


WITH_INT_DISK $SSW/yohkoh/ucon/idl/hudson/with_int_disk.pro
[Previous] [Next]
 NAME:
	      WITH_INT_DISK
 PURPOSE:
	      integrate Withbroe models to find the brightness of
	        a coronal hole on the disk. See WITHBROE for
	        model details and a reference.
 CATEGORY:
	      Yohkoh stuff
 CALLING SEQUENCE:
	      flux = with_int_disk(model_type, angle, int_step = int_step)
 INPUTS:
	      type of Withbroe model (see WITHBROE); 3 => polar hole (min)
	      angle to vertical (degrees, 90 => limb)
 OPTIONAL (KEYWORD) INPUT PARAMETERS:
       int_step the number of integration steps (default 100) per 10 R_sun
 OUTPUTS:
	      flux(2) the SXT fluxes for thin Al and Dag. The units are DN/pix/sec
         for full-resolution pixels
 CALLS: ***
	WITHBROE, gt_pix_size, sxt_flux [1], sxt_flux [2], sxt_flux [3]
 COMMON BLOCKS:
 SIDE EFFECTS:
 RESTRICTIONS:
 ROUTINES CALLED:
	      WITHBROE, SXT_FLUX, GT_PIX_SIZE
 MODIFICATION HISTORY:
       HSH Mar. 30, 1994 (see WITH_INT)
	      HSH Apr.  3, 1994 fixed bugs, converted to full res pixels 


WITHBROE $SSW/yohkoh/ucon/idl/hudson/withbroe.pro
[Previous] [Next]
 NAME:
	WITHBROE
 PURPOSE:
	generate Withbroe's coronal models:
	  0. quiet corona
	  1. polar coronal hole (max)
	  2. equatorial coronal hole (min)
	  3. polar coronal hole (min)
	reference G.L. Withbroe, Ap. J. 325, 442, 1988
 CATEGORY:
 CALLING SEQUENCE:
	coronal_parameters = withbroe(radii, model)
 INPUTS:
	radii to calculate at (monotonic, R_sun, increasing between 1. and 10.)
	model number (listed above)
 OUTPUTS:
	coronal_parameters(4, nn) 
	  nn = number of radii
	  0:3 = radii, temperature, density, velocity
 CALLS: ***
	DSPLINE
 CALLED BY:
	WITH_INT, WITH_INT_DISK, lineofsight [1], lineofsight [2], plotwith
 RESTRICTIONS:
	no velocities yet except for model 1
 MODIFICATION HISTORY:
	HSH written 2-Sep-93
	HSH incorporated DSPLINE 3-Sep-93
       CAF completed the inputs ~1995     


WJPEG $SSW/yohkoh/ucon/idl/wuelser/wjpeg.pro
[Previous] [Next]
 NAME:
        WJPEG
 PURPOSE:
        Write a grayscale image in JPEG/JFIF format (lossy compression).
 CATEGORY:
 CALLING SEQUENCE:
        rjpeg,image,file
 INPUTS:
        image = byte array (2-D).
        file = string.  File name.
 KEYWORDS (INPUT):
        quality = integer between 5 and 95.  Default = 75.
                  Higher number gives better image quality but lower
                  degree of compression (-> bigger file).
 OUTPUTS:
        No explicit output.
 KEYWORDS (OUTPUT):
 COMMON BLOCKS:
        None.
 SIDE EFFECTS:
        A file is created.
 RESTRICTIONS:
        Only greyscale output possible.
        (It's really just a quick-and-dirty program).
 PROCEDURE:
        WJPEG is a primitive IDL frontend to CJPEG, a C program from the
        Independent JPEG Group.  CJPEG is spawned and receives the image
        through a pipe in simple PGM format.
 MODIFICATION HISTORY:
        JPW, 14-nov-94
        JPW, 23-nov-94  flipped image in y (JPEG: top-down, IDL: bottom-up)


wk_online $SSW/yohkoh/gen/idl/mo_disk/wk_online.pro
[Previous] [Next]
	NAME: wk_online
	Purpose: return the path to a requested data week.
	
	Calling Sequence:
		wk_path = wk_online( week )
		
		week 	is a valid data week name week(s) 
			
	Input:
		week	i.e. '93_14' or '93_14a'...
	Output:
	      	Path of each found week.  Returns null string for
		weeks that are not found.
 CALLS: ***
	finddir [1], finddir [2]
 CALLED BY:
	cp_fns [1], cp_fns [2], mk_mo2 [1], mk_mo2 [2], mo_tap_dump
	HISTORY:
		written 13-May-93, gal
		26-May-93 (MDM) - Modified to look for b,c,d, and t
				  directories in addition to a directories
		26-May-93, gal, added m-type directory.


wl_averagerdata_inavg_imgmask_img $SSW/yohkoh/ucon/idl/hudson/wl_averager.pro
[Previous] [Next]
 NAME:
	wl_averager,data_in,avg_img,mask_img
 PURPOSE:
	generate an average image from a data cube, with interactive
	  elimination of unwanted regions one at a time
 CATEGORY:
 CALLING SEQUENCE:
 INPUTS:
	data_in is a data cube of WL data
 OPTIONAL (KEYWORD) INPUT PARAMETERS:
 OUTPUTS:
	avg_img is the average image
	mask is an image containing the number of good points per pixel
 CALLS: ***
	HH_DELETE, WL_AVERAGER
 COMMON BLOCKS:
 SIDE EFFECTS:
 RESTRICTIONS:
	be careful to delete something from each image (bug!)
	won't give an output if the mask is zero anywhere
	is painfully slow
	needs to be run in the right directory
 MODIFICATION HISTORY:
	HSH 31 Oct 1993


WL_CUBE_II $SSW/yohkoh/ucon/idl/hudson/wl_cube_ii.pro
[Previous] [Next]
 NAME:
       WL_CUBE_II
 PURPOSE:
       Prepare aligned difference images for WL flare studies
 CATEGORY:
       Yohkoh
 CALLING SEQUENCE:
       wl_cube_ii,infil,index,diff,image
       wl_cube_ii,infil,index,diff,/clean,/plot
       wl_cube_ii,'/yd6/flares/spr911115.2141',index,diff
 INPUTS:
       infil is the file ID for an SPR data set with a flare in it
 OPTIONAL (KEYWORD) INPUT PARAMETERS:
       CLEAN removes spikes and the outer boundary to make a cleaner
         display
       PLOT plots the time series of total signal
       NOT_LAST steps back from the last image as a reference, by the
         value specified (not_last = 1 => next to last)
 OUTPUTS:
       index is the index array of the NaBan images
       diff is the difference images relative to the last image;
         sxt_prep,/register has been used to register
       image is the first image of the data cube, useful for overlaying
         sunspot positions etc.
 ROUTINES USED
       SXT_PREP, RD_XDA, TIM2DSET, RESTORE_LOW8, misc. GT_'s, SPIKES_OFF, 
         KILL_INDEX
 CALLS: ***
	FMT_TIMER [1], FMT_TIMER [2], KILL_INDEX [1], KILL_INDEX [2], RD_XDA [1]
	RD_XDA [2], UTPLOT [1], UTPLOT [2], UTPLOT [3], UTPLOT [4], UTPLOT [5], UTPLOT [6]
	gt_comp, gt_dp_mode [1], gt_dp_mode [2], gt_expdur [1], gt_expdur [2], gt_filta
	spikes_off, sxt_decomp [1], sxt_decomp [2], sxt_prep [1], sxt_prep [2]
	sxt_prep [3], tbeep [1], tbeep [2], tbeep [3]
 MODIFICATION HISTORY:
       HSH converted from WL_CUBE_MAKER 13-Jun-94


wl_process $SSW/yohkoh/ucon/idl/mcallister/wl_process.pro
[Previous] [Next]
       NAME: wl_process


       PURPOSE: To process the SXT aspect sensor images and generate limbdarkening
		 profiles, flat field images, white light images minus the dark
		 current, flat field, and limbdarkening signals.


       METHOD: First you select the images to process. Darkframe removal is 
		performed. Single image limbdarkening profiles are created and
		subtracted, and major sunspots are removed, before batch averaging
		is done to derive the flat fields. These are removed from the 
		dark frame corrected data, which are then aligned. Limbdarkening
		profiles are made again, and averaged over the batches. Finally
		fully processed images are created and stored to disk. The batch
		averaged darkening profiles and flatfields are also stored.
		The processing is done in batches of 10 unless the INC keyword 
		is set. This should be set depending on your machines memory
		capacity, and such as to break the dataset evenly, if there is
		a small left over batch at the end the results may be poor.
		In averaging for the flatfields 4-6 images are taken at
		intervals.


       CALLING SEQUENCE:	wl_process,infil[,inc=inc][,sscf=sscf][plcf=plcf]
						[,/saa][,/night][,/all]


       PARAMETERS:	infil	 	path/filename of SXT white light file 


       KEYWORDS:	inc		size of batches to process. This will vary
					depending on your machine's memory and the
					number of selected images.
			sscf		set cutoff for "sunspots", > flatfield 
			plcf		factor to set plage cutoff, in flatfield
			all		take all image in the file
			saa		when set omit images taken in saa
			night		when set omit images within 1 min of S/C night

	CALLS: ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], RD_XDA [1], RD_XDA [2], TARGET [1]
	align_cube, area_mean, break_file [4], dark_sub [1], dark_sub [2], dark_sub [3]
	gt_expdur [1], gt_expdur [2], gt_res, his_index, mod_res, rad_bck, rt_sxtdt
	sav_sda [1], sav_sda [2], sav_sda [3], set_back, spikes [1], spikes [2], target [2]
	tim2orbit [1], tim2orbit [2]
       HISTORY: Drafted by A. McAllister jun-93
		 First release version, 16-jun-93, AMcA.
		 Fixed data useage and cleanup, 1-jul-93, AMcA.
		 Corrected application of SAA keyword, 25-jan-94, AMcA.
		 Enhanced cosmic ray removal, 26-jan-94, AMcA.
		 Added code to enlarge QR's in mixed sets, 27-jan-94, AMcA.
		 Added call to SET_BACK before second LD pass, 2-feb-94, AMcA.
		 Version 1.1  feb-2-94, AMcA.
		 Use target in second call to RAD_BCK, feb-8-94, AMcA.
		 Fixed the background at -100., feb-9-94, AMcA.
		 Fixed indexing bug in resolution code, feb-10-94, AMcA.
		 Replaced call to SXT_CENTER with call to GEN_LOC, feb-11-94, AMcA.
     		 Removed new target formation after alignment, feb-14-94, AMcA.
		 Version 1.2 feb-15-94, AMcA.


wmkkey [2] $SSW/yohkoh/gen/idl/dbase/wmkkey.pro
[Previous] [Next]
   Name: wmkkey

   Purpose: make widget for key search input

 CALLS:
 CALLED BY
	mk_key


wmkkey_event [2] $SSW/yohkoh/gen/idl/dbase/wmkkey_event.pro
[Previous] [Next]
   Name: wmkkey_event

   Purpose: handle wmkkey events - generate search string

 CALLS: ***
	CLRKEYS, getcurstr [1], getcurstr [2]
   History: slf, 1/3/91
	some mods made Jan-91 by GAL for keymain.pro
	24-Jan-92, fixed "quit" exit to return "saved key list"


WOBS_PLOT $SSW/yohkoh/ucon/idl/bentley/wobs_plot.pro
[Previous] [Next]
 NAME:
	WOBS_PLOT
 PURPOSE:
	Widget front-end to the OBS_PLOT procedure
 CATEGORY:
 CALLING SEQUENCE:
	wobs_plot,tstart [,duration=duration]

	wobs_plot
	wobs_plot,'16-dec-91 04:30'
	wobs_plot,'16-dec-91 04:30','16-dec-91 05:15'
	wobs_plot,'16-dec-91 04:30',dur=45
 OPTIONAL INPUT PARAMETERS:
	tstart		start time (UT) of plot
                       (uses now - 48hrs if none specified)
	tstop           stop time (UT) of plot
			(uses default duration if not specified)
 KEYWORD PARAMETERS:
	duration	duration of plot (mins)
			(uses default duration if none specifed)
	debug		if set, additional information printed
 OUTPUTS:
 OPTIONAL OUTPUT PARAMETERS:
 CALLS: ***
	ADDTIME [1], ADDTIME [2], OBS_SETUP, OBS_WIDGET, anytim2ex [1], anytim2ex [2]
	anytim2ints [1], anytim2ints [2], fid2ex [1], fid2ex [2], fmt_tim [1], fmt_tim [2]
	systime2 [1], systime2 [2]
 COMMON BLOCKS:
	obs_cm2 and obs_times
 SIDE EFFECTS:
	calls widgets as prelude to call to obs_Plot
 RESTRICTIONS:
	Needs and X-terminal
 PROCEDURE:
	Determines stop time from either specified value, or duration, or
	default duration. Passes in common and uses widget to determine other 
	desired call paramaters before doing call to OBS_PLOT.
       Plots last 48 hrs of data if no parameters specified.
 MODIFICATION HISTORY:
	RDB     Feb-95  Written
	RDB	May-95	Added hardcopy and sfm plot
       RDB  13-Nov-97  Many improvements


word_conv [2] $SSW/yohkoh/gen/idl/util/word_conv.pro
[Previous] [Next]
NAME:
	word_conv
PURPOSE:
	Converts data written on a DEC machine to SUN format by swapping
	bytes appropriately for the type of the input data.  Optionally
	convert REALs between IEEE and VAX format.
SAMPLE CALLING SEQUENCE:
	word_conv, a
INPUTS:
	a = input variable which is to have its bytes swapped
OPTIONAL KEYWORD INPUT PARAMETERS:
	ieee2vax - If set, then convert the REALs from IEEE to VAX format
	vax2ieee - If set, then convert the REALs from VAX to IEEE format
OUTPUTS:
	a = reformatted variable is passed back in the original variable
 CALLS: ***
	ieee2vax [1], ieee2vax [2], vax2ieee [1], vax2ieee [2]
COMMON BLOCKS:
	None
SIDE EFFECTS:
	None
RESTRICTIONS:
	None
PROCEDURE:
	Determines the type of the variable and swaps the bytes depending
	on the type.  If the variable is a structure, the tags are 
	recursively searched so that the bytes are swapped throughout
	the structure.
MODIFICATION HISTORY:
	T. Metcalf 5/20/91  Version 1.0
       T. Metcalf Aug 1991: Added complex floating point  Version 1.1
       T. Metcalf Nov 1991: Converted vax2sun to dec2sun
	13-Apr-93 (MDM) Took DEC2SUN and modified it into WORD_CONV


wprepWidget Prep $SSW/yohkoh/ucon/idl/lemen/wprep.pro
[Previous] [Next]
  Name:
    wprep		(Widget Prep)

  Purpose:
    Set the number of colors for the X-display.

  Calling Sequence:
    wprep			; N_colors defaults 246
    wprep,N_colors

  Inputs:
    N_colors	= Number of colors (if absent, defaults to 241)

 CALLS: ***
	WPREP
  Modification History:
    Written, 4-may-92, J. R. Lemen
    Modified, 6-jun-92, JRL Change default to 241 (for isassX machines)
'			     Also changed the name (from CS)


wr_bpc $SSW/yohkoh/bcs/idl/bsd/wr_bpc.pro
[Previous] [Next]
  wr_bpc,filename,datablock

  procedure to read a BPC file and load the results into a structure
  for easy access for plotting etc

  The structure definition is.......

 ARRAY(chan,spec).QUALITY(option,line)
 ARRAY(chan,spec).INTENSITY(option,line)
 ARRAY(chan,spec).IERR(option,line)
 ARRAY(chan,spec).WIDTH(option,line)
 ARRAY(chan,spec).WERR(option,line)
 ARRAY(chan,spec).POSITION(option,line)
 ARRAY(chan,spec).PERR(option,line)
 ARRAY(chan,spec).BACK1(option,line)
 ARRAY(chan,spec).BACK2(option,line)
 ARRAY(chan,spec).TIME(6)
 ARRAY(chan,spec).WO(3)
 ARRAY(chan,spec).DW
 ARRAY(chan,spec).NBACK
 ARRAY(chan,spec).NOPT_USED
 ARRAY(chan,spec).TOTAL
 ARRAY(chan,spec).SDGI

 Use:   First note that all counters start at zero!
        Produce a BPC file by using MKBSD, BSDCAL then

        idl>  rd_bpc,array,'bpc file name'

        idl> plot,array(3,*).intensity(1,2)   would then plot all the
                                              intensities derived for the
                                              3rd line in the second fit
                                              option of the SXV channel - 
                                              if such a beast were to exist.


     CDP  Nov 91

 CALLED BY
	BCS_FIXBPC


wr_bsd v01 $SSW/yohkoh/bcs/idl/bsd/wr_bsd.pro
[Previous] [Next]
	NAME:		wr_bsd v.01

	PURPOSE:
		write a new bsd file 

	CALLING SEQUENCE:
		wr_bsd, lun_filnam, header, index, data

	INPUT:
		lun_filnam	input file specification or the
				unit number of an opened BSD file

               Header 		The BSD_header structure for the current file.

		index		the bsd index Structure

		data		bsd data structure

		(for defintions of the above see bsd_struct.pro)

	OUTPUT: A file is written containing the new bsd structures
		 
       NOTES:  Known `features' 
			1) data channels must have the correct index records
		associated with them or else the file gets scrambled.
			2) A new roadmap is worked out.
			3) If a channel has no data in dataset 0 - indicated
		by having bsd_index(0,chan).chan = 0 - then the entire
		channels' worth of data will be ignored.
			4) think of it as a beta test... 
                       5) the files produced are not 16 byte records.
		or 64 even. - stream on unix, fixed 512 (probably) vms

 CALLS: ***
	BSD_STRUCT, WR_BSD
	HISTORY:
 		atp: may 1992 
		MDM: Modification to allow less than 4 channels to be saved


WR_CPU_DTB $SSW/yohkoh/bcs/idl/micro/wr_cpu_dtb.pro
[Previous] [Next]
 NAME:
	WR_CPU_DTB
 PURPOSE:
	Write modifies BCS list database files
 CATEGORY:
 CALLING SEQUENCE:
	wr_cpu_dtb,type,database,ierror
 INPUTS:
	type		type of list datbase to be modfied, allowed are
			'FLOP', 'SEQN', 'PLAN'
	database	structure containing modifies database
 OPTIONAL INPUT PARAMETERS:
 KEYWORD PARAMETERS:
 OUTPUTS:
	ierror		set to -1 if there was an error, otherwise zero
 OPTIONAL OUTPUT PARAMETERS:
 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], chktag, concat_dir [4]
 COMMON BLOCKS:
 SIDE EFFECTS:
 RESTRICTIONS:
 PROCEDURE:
	Checks that structure matches type and then writes modified database
 MODIFICATION HISTORY:
	RDB  17-May-94	Written
			Used .planid (instead of .grpid) for reformatter compatability
			Made file /xdr


wr_filehex $SSW/yohkoh/gen/idl/orbit/wr_ophex.pro
[Previous] [Next]
  Name:
    wr_filehex

  Purpose:
    Write hex file for op_first_guess

 CALLS: ***
	WR_OPHEX
  Modification History:
    Written,  21-oct-91, J. R. Lemen
    Modified, 11-Jan-92, J. R. Lemen  -- increase max entries from 128 to 152
   6-dec-93, JRL, If a 000000 time occurs, convert it to 240000


WR_FULL_LOAD $SSW/yohkoh/bcs/idl/atest/wr_full_load.pro
[Previous] [Next]
 NAME:
	WR_FULL_LOAD
 PURPOSE:
	Writes image of BCS memory load into requested file
	default is: $DIR_BCS_MICRO:full_load.dat_yymmdd
 CATEGORY:
 CALLING SEQUENCE:
	wr_full_load,full_load
 INPUTS:
 OPTIONAL INPUT PARAMETERS:
 KEYWORD PARAMETERS:
	file=file	used as file name if present
	/overwrite	allows overwrite of existing file
	/debug		tells what file it would write to
 OUTPUTS:
 OPTIONAL OUTPUT PARAMETERS:
 CALLS: ***
	ANYTIM2FID, systime2 [1], systime2 [2]
 COMMON BLOCKS:
 SIDE EFFECTS:
 RESTRICTIONS:
 PROCEDURE:
 MODIFICATION HISTORY:
	RDB   28-Nov-97  Written


wr_nvs $SSW/yohkoh/gen/idl/movie/wr_nvs.pro
[Previous] [Next]
  NAME:
   wr_nvs

  PURPOSE:

   Write a binary file that can be read by the nvs (Network Video Server)

   The size of the file will be the ysize of img0, and the sum of the
   xsizes of img0 and img1

  CALLING SEQUENCE:
	wr_nvs,img0,img1,color_tab,color_tab2,		$
		file=filename,raw_mode=raw_mode,out=out

  RESTRICTION:
   img0 and img1 must by byte arrays
   The y sizes of img0 and img 1 must be equal unless img1 = 0.
   If img1 = 0, then only one image is written.

 CALLED BY:
	mk_movie [1], mk_movie [2], mk_nvs_movie, mk_ptv_movie
  MODIFICATION HISTORY:
   25-jan-92, Written, J. R. Lemen
    4-sep-92, Modified, JRL -- Enable img1 =0 option.


wr_opasc [1] $SSW/yohkoh/gen/idl/atest/wr_opasc.pro
[Previous] [Next]
  Name:
     wr_opasc

  Purpose:
     Write ascii file output for op_first_guess

 CALLS: ***
	PRINT_OP_RULES, fmt_tim [1], fmt_tim [2]
  History:
     19-oct-91, Written, J. Lemen
     10-dec-91, Updated, J. Lemen, Add KSC and DSN summary information
      6-jul-92, Updated, J. Lemen, Force a Form-Feed before station summary.
      5-aug-92, Updated, J. Lemen, Don't print blank Station summary lines.
     27-apr-93, JRL  Changed the way the system time was being calculated.
     14-oct-93, JRL, Added the terminator keyword.
     30-jul-94, JRL, Changed the KSC pass elimination message.
      7-mar-97, JRL, Added info about BDR optimization and terminator requests


wr_opasc [2] $SSW/yohkoh/gen/idl/orbit/wr_opasc.pro
[Previous] [Next]
  Name:
     wr_opasc

  Purpose:
     Write ascii file output for op_first_guess

 CALLS: ***
	PRINT_OP_RULES, fmt_tim [1], fmt_tim [2]
  History:
     19-oct-91, Written, J. Lemen
     10-dec-91, Updated, J. Lemen, Add KSC and DSN summary information
      6-jul-92, Updated, J. Lemen, Force a Form-Feed before station summary.
      5-aug-92, Updated, J. Lemen, Don't print blank Station summary lines.
     27-apr-93, JRL  Changed the way the system time was being calculated.
     14-oct-93, JRL, Added the terminator keyword.
     30-jul-94, JRL, Changed the KSC pass elimination message.


wr_peritek $SSW/yohkoh/gen/idl/movie/wr_peritek.pro
[Previous] [Next]
  NAME:
   wr_peritek

  PURPOSE:
   Write a binary file to the peritek display interface.

   The size of the file will be the ysize of img0, and the sum of the
   xsizes of img0 and img1

  RESTRICTION:
   The y sizes of img0 and img 1 must be equal.
   img0 and img1 must by byte arrays

 CALLS: ***
	PTV
 CALLED BY:
	mk_movie [1], mk_movie [2], mk_ptv_movie, ptv_sxt
  MODIFICATION HISTORY:
   	Written, GAL, 14-Aug-92
	19-Jul-94, GAL, allow qdisplay options


WR_PLAN_AREA $SSW/yohkoh/bcs/idl/micro/wr_plan_area.pro
[Previous] [Next]
 NAME:
	WR_PLAN_AREA
 PURPOSE:
	writes a modified plan area and history
 CATEGORY:
 CALLING SEQUENCE:
	wr_plan_area,plan_area,history
 INPUTS:	
	plan_area	512 byte plan area
	history		history records of changes (must be passed!)
 OPTIONAL INPUT PARAMETERS:
 KEYWORD PARAMETERS:
 OUTPUTS:
 OPTIONAL OUTPUT PARAMETERS:
 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], concat_dir [4], timstr2ex [1]
	timstr2ex [2], yesnox [1], yesnox [2]
 COMMON BLOCKS:
 SIDE EFFECTS:
 RESTRICTIONS:
	hsitory records must be passed
 PROCEDURE:
 MODIFICATION HISTORY:
	RDB  14-May-94	Extracted into own routine, some mods to file format
	RDB  17-May-94	Made file /xdr


wr_sda $SSW/yohkoh/ucon/idl/linford/wr_sda.pro
[Previous] [Next]
	NAME: wr_sda
	PURPOSE: write the input index and data to a sda-type file.

	CALLING SEQUENCE:
		wr_sda, 'sdaOutput_file', indices, index, data

 CALLS: ***
	sav_sda [1], sav_sda [2], sav_sda [3]
	example:
	    IDL> wr_sda, 'my_sda_file', index, data
		(to save an array of data-indices and data to a file)

	where:
		sdaOutput_file	is the name of the created file
		indices		list of indices to save to the file
			note: if equal to -1 saves all elements to file.
		index		data-index structure array
		data		data cube

	Method:
		Uses sav_sda to write an array of indexs and images to
		a sda-type file with one call!
		
	History:
		written 4-Apr-94, gal


wr_selsisi_dir $SSW/yohkoh/gen/idl/gbo/wr_selsisi_dir.pro
[Previous] [Next]
NAME:
	wr_selsisi_dir
PURPOSE:
	To append to the SELSIS image directory file listing file for
	images that have been copied over
CALLING SEQUENCE:
	wr_selsisi_dir, dirlist
 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], concat_dir [4]
 CALLED BY:
	selsisi_copy
OPTIONAL KEYWORD INPUT:
	infil	- The input file.  If not defined it is 
		  $DIR_GBO_SELSISI/copy_directory.lis
HISTORY:
	Written 2-Jul-92 by M.Morrison


WR_TXT $SSW/yohkoh/ucon/idl/kawai/wr_txt.pro
[Previous] [Next]
NAME:   WR_TXT
PURPOSE:
         save string array as a text file.
CATEGORY:
CALLING SEQUENCE:
         WR_TXT, LINES, FILENAME=FILENAME
INPUTS:
         LINES: string array = text lines to be written
OPTIONAL INPUT
         FILENAME : string = File name
                    when omitted, you are prompted to type
                    a filename.
OUTPUTS:        
COMMON BLOCKS:
SIDE DEFFECTS:
         A text file is created.
RESTRICTIONS:
MODIFICATION HISTORY:
EXAMPLES:


wrap $SSW/yohkoh/ucon/idl/metcalf/wrap.pro
[Previous] [Next]
 Returns  an array in wraparound order
 Due to the inflexibility of IDL's SHIFT command each number of
 dimensions is handled separately by NDSHIFT. If an error occurs, 
 the original input array is returned.
 Input parameter:
 ARRAY (Array) - array to be wrapped around by 1/2 its dimensions.

 Calls: ***
	ndshift
 History:
 17 August 1993- new version by P. R. Blanco, CASS/UCSD, based on
 the original routine by R. K. Pina. Handles 0 to 5 dimensions.


WRITE_GRSPH $SSW/yohkoh/ucon/idl/hiraoka/write_grsph.pro
[Previous] [Next]

 NAME:
       WRITE_GRSPH
 PURPOSE:
       To write WBS grs_phl spectrum data on the text file for spfd. 
 CALLING SEQUENCE:
       write_grsph,flph,bkph
       write_grsph,flph
         ( If you do not extract the background data, no background-
           subtracted data are written. )
 INPUTS:
       flph - WBS_GRSPHL structure. ( flare data )
       bkph - WBS_GRSPHL structure. ( background data )
         ( after the run of out_grsphl1 or out_grsphl2 and the extract of 
           'flph','bkph'. )
 OPTIONAL INPUTS:
       fn   - File name. If not present, fn is 'GRS_SPECTRUM.DATA'.
 CALLED BY:
	TEST_OUTG
 HISTORY:
       Written 9-dec-93 by T.Hiraoka ( Rikkyo Univ.)


WRITE_HXSPH $SSW/yohkoh/ucon/idl/hiraoka/write_hxsph.pro
[Previous] [Next]

 NAME:
       WRITE_HXSPH
 PURPOSE:
       To write WBS hxs_ph spectrum data on the text file for spfd. 
 CALLING SEQUENCE:
       write_hxsph,flph,bkph
       write_hxsph,flph
         ( If you do not extract the background data, no background-
           subtracted data are written. )
 INPUTS:
       flph - WBS_HXSPH structure. ( flare data )
       bkph - WBS_HXSPH structure. ( background data )
         ( after the run of out_hxsph and the extract of 'flph','bkph'. )
 OPTIONAL INPUTS:
       fn   - File name. If not present, fn is 'HXS_SPECTRUM.DATA'.
 CALLED BY:
	TEST_OUTH
 HISTORY:
       Written 9-dec-93 by T.Hiraoka ( Rikkyo Univ.)


wrt1cba $SSW/yohkoh/gen/idl/reformat/wrt1cba.pro
[Previous] [Next]
NAME:
	wrt1cba
PURPOSE:
	Write one record of the CBA file (called exclusively
	by the reformatter)
INPUT:
	rec1
	gen_index
	lun
	bytout
 CALLS: ***
	GET_NBYTES, REF_STRUCT, rdwrt [1], rdwrt [2], rdwrt [3]
HISTORY:
	Written Fall '91 by M.Morrison
	 6-Mar-92 (MDM) Changed to not write out "mat2" which was
			the ground derived time information.


wrt1orbit [1] $SSW/yohkoh/gen/idl/atest/wrt1orbit.pro
[Previous] [Next]
NAME:
	wrt1orbit
PURPOSE:
	Procedure that writes part of a 24 hour file into a 
	single orbit file.
INPUT:
	infil	- the input file name
	prefix	- the file prefix (ie: bda, sfr, ...)
	instr	- the instrument (ie: bcs, sxt, ...)
	dir_out	- the output directory array - need to match the input file (.ifil) with the proper output directory
	fileid_out- the fileid for the output file
	dset_str- a list of data set #'s which satisfy the time range requirement
	dp_arr	- a list of dp_sync record #'s which satisfy the time range requirement
	progname- the program name (for file header)
	roadmap	- the roadmap for "infil" (passed so that each time RD_ROADMAP and RD_XDA is called it does not re-read the
		  roadmap
	orbit_times- a structure holding the starting/ending orbit times for this file
	overwrite- If set, clobber the existing file if it exists.
 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], GET_NBYTES, OPEN_DA_FILE, RD_QS
	RD_XDA [1], RD_XDA [2], Rd_Pointer [1], Rd_Pointer [2], Rd_fHeader [1]
	Rd_fHeader [2], Rd_fHeader [3], UNIQ [1], UNIQ [2], UNIQ [3], WRT1P_FH, WRTATTMAP
	WRTBCSMAP, WRTCBAMAP, WRTHXTMAP, WRTWBSMAP, concat_dir [4], fmt_tim [1], fmt_tim [2]
	int2secarr [1], int2secarr [2], rdwrt [1], rdwrt [2], rdwrt [3], wrtsxtmap
HISTORY:
	Written Fall '91 by M.Morrison
	 9-Mar-92 (MDM) Various changes to get it working for the 
			first "official" data tape distribution
	17-Apr-92 (MDM) Significant re-organization of the code
			Arranged so that duplicate images are combined
			together (there can be images that are split because
			of 24 hr boundary on the raw telemetry files, or because
			of anomalous triggers during reformatting)
	17-Apr-92 (MDM) Changed so that RD_XDA is not called for each dataset
			(it was too slow, even with the mods to RD_XDA to only
			re-read the roadmap when necessary).  It reads all
			datasets once except for the FFI case.
	24-Apr-92 (MDM) - Updated so that duplicate FFI images only are
			  added for where there is new data (used to add to
			  complete images because SIRIUS gave overlaps in data).
	24-Jun-92 (MDM) - Adjusted to not write out duplicate copies of datasets
			  which was happening because SIRIUS was giving 
			  duplicate overlap stuff.  WBS required some special
			  modifications too
	12-Apr-95 (MDM) - Modified to not count the fill data ("AA" hex) when
			  calculating the percentage of the image when recombining
			  two SXT images.


wrt1orbit [2] $SSW/yohkoh/gen/idl/reformat/wrt1orbit.pro
[Previous] [Next]
NAME:
	wrt1orbit
PURPOSE:
	Procedure that writes part of a 24 hour file into a 
	single orbit file.
INPUT:
	infil	- the input file name
	prefix	- the file prefix (ie: bda, sfr, ...)
	instr	- the instrument (ie: bcs, sxt, ...)
	dir_out	- the output directory array - need to match the input file (.ifil) with the proper output directory
	fileid_out- the fileid for the output file
	dset_str- a list of data set #'s which satisfy the time range requirement
	dp_arr	- a list of dp_sync record #'s which satisfy the time range requirement
	progname- the program name (for file header)
	roadmap	- the roadmap for "infil" (passed so that each time RD_ROADMAP and RD_XDA is called it does not re-read the
		  roadmap
	orbit_times- a structure holding the starting/ending orbit times for this file
	overwrite- If set, clobber the existing file if it exists.
 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], GET_NBYTES, OPEN_DA_FILE, RD_QS
	RD_XDA [1], RD_XDA [2], Rd_Pointer [1], Rd_Pointer [2], Rd_fHeader [1]
	Rd_fHeader [2], Rd_fHeader [3], UNIQ [1], UNIQ [2], UNIQ [3], WRT1P_FH, WRTATTMAP
	WRTBCSMAP, WRTCBAMAP, WRTHXTMAP, WRTWBSMAP, concat_dir [4], fmt_tim [1], fmt_tim [2]
	int2secarr [1], int2secarr [2], rdwrt [1], rdwrt [2], rdwrt [3], wrtsxtmap
HISTORY:
	Written Fall '91 by M.Morrison
	 9-Mar-92 (MDM) Various changes to get it working for the 
			first "official" data tape distribution
	17-Apr-92 (MDM) Significant re-organization of the code
			Arranged so that duplicate images are combined
			together (there can be images that are split because
			of 24 hr boundary on the raw telemetry files, or because
			of anomalous triggers during reformatting)
	17-Apr-92 (MDM) Changed so that RD_XDA is not called for each dataset
			(it was too slow, even with the mods to RD_XDA to only
			re-read the roadmap when necessary).  It reads all
			datasets once except for the FFI case.
	24-Apr-92 (MDM) - Updated so that duplicate FFI images only are
			  added for where there is new data (used to add to
			  complete images because SIRIUS gave overlaps in data).
	24-Jun-92 (MDM) - Adjusted to not write out duplicate copies of datasets
			  which was happening because SIRIUS was giving 
			  duplicate overlap stuff.  WBS required some special
			  modifications too
	12-Apr-95 (MDM) - Modified to not count the fill data ("AA" hex) when
			  calculating the percentage of the image when recombining
			  two SXT images.


WRT_BSDCAL_CFL $SSW/yohkoh/bcs/idl/bsd/wrt_bsdcal_cfl.pro
[Previous] [Next]
 NAME:
	WRT_BSDCAL_CFL
 PURPOSE:
       Write control file for the BSDCAL F77 programme
 CALLING SEQUENCE:  
	wrt_bsdcal_cfl,filename [,directory=directory] [,etc...]
 INPUTS:
	filename	fileid of BSD file
 KEYWORD INPUTS:
	directory	directory that BSD file is on
	spectra		spectra number within file to be used (default = all)
	chans		channels to be processed (default is 2,3,4)
	two_comp	if set, two components are processed (def = n)

       cfl_name        Name of CFL           (def = qqq.cfl)

 OUTPUTS:
	None
 CALLS: ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], CONCAT_DIR [1], CONCAT_DIR [2]
	CONCAT_DIR [3], break_file [4], concat_dir [4]
 SIDE EFFECTS:
	Writes a .cfl for BSDCAL programme on current directory
	Default name for this is qqq.cfl
 RESTRICTIONS:
	Only some of parameters can be set - rest are defaults
 PROCEDURE:
	Uses input to define some items. Writes first 13 lines of BSDCAL
	control file from these; copies rest of file from template on
	directory $DIR_BCS_EXE  (bsdcal-04.cfl)
 MODIFICATION HISTORY:
	RDB  03-Jul-92
	RDB  28-Oct-92  Added the two_comp and chans options
	RDB  21-Jan-93  Strip blank lines on write (Alpha feature!)
	RDB   6-Jun-93	Added cfl_name keyword option


WRT_BSDFIT_CFL $SSW/yohkoh/bcs/idl/bsd/wrt_bsdfit_cfl.pro
[Previous] [Next]
 NAME:
	WRT_BSDFIT_CFL
 PURPOSE:
	Write control file for the BSDFIT F77 programme
 CALLING SEQUENCE:  
	wrt_bsdfit_cfl,filename [,directory=directory] [,spectra=spectra]
 INPUTS:
	filename	fileid of BSD file
 OPTIONAL INPUTS:
	directory      	directory that BSD file is in
	spectra        	spectra number within file to be used (default = all)
	chans		channels to be processed (default = 2,3,4)
	two_comp	if present, two component fit done

       cfl_name        Name of CFL           (def = ppp.cfl)

 OUTPUTS:
	None
 CALLS: ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], break_file [4]
 SIDE EFFECTS:
       Produces a .CFL file on the current directory
       Default name for this is "ppp.cfl"
 RESTRICTIONS:
	Only some of the paramaters can be set - the rest are defaults
 PROCEDURE:
	Uses inpuit to define some items. Rest are defaults.

 MODIFICATION HISTORY:
	RDB  03-Jul-92
	RDB  07-Jul-92	Translate env. variable $DIR_BCS_* in Unix
	RDB  08-Jul-92	Added CHANS keyword
	RDB  25-Jul-92	Version 2 of CFL
	RDB  28-Oct-92  Added two_comp switch
	RDB   6-Jun-93	Added cfl_name keyword option
	RDB   7-Jun-93	Vesrion 3


WRT_GEN [2] $SSW/yohkoh/gen/idl/util/wrt_gen.pro
[Previous] [Next]
 NAME:
 	WRT_GEN

 PURPOSE:
	Write SXT generic file 

 CALLING SEQUENCE:
	WRT_GEN, filename, data [,TEXT=TEXT, SUCCESS, /REPLACE] 

 INPUTS:
	DATA - data to save (simple structure, n-dimen array, or scaler)
	FILENAME - string containing generic file name

 OPTIONAL KEYWORD PARAMETERS:
 	TEXT -    (Input) Generic file text description
	REPLACE - (Input) If set , forces overwriting of existing file
	HEADER -  (Output) Returns ystem imposed header (version/creattion date)
	SUCCESS - (Output) Returns success code

 FILE I/O:
  	If succesful, named file is created or updated (overwritten) 

 COMMON BLOCKS;
	NONE

 CALLS: ***
	ARR2STR [1], Arr2Str [2], FILE_EXIST [2], MAKE_STR [1], MAKE_STR [2]
	file_exist [1], file_exist [3]
 RESTRICTIONS:
	Version 00 does not support nested structures for DATA

 MODIFICATION HISTORY:
	Version 0 - SLF, 3/5/91
		    slf, 19-dec-1992 changed variable name to function call
			             variable/function conflict (file_exit)
				     force text to be scaler string


WRT_HOST_PTH $SSW/yohkoh/bcs/idl/util/wrt_host_path.pro
[Previous] [Next]
 NAME:
	WRT_HOST_PTH
 PURPOSE:
	Write path of host to the file "HOST_PATH.LIS"
 CALLING SEQUENCE:  
	.run WRT_HOST_PATH
 INPUTS:
	None
 OUTPUTS:
	Creates file HOST_PATH.LIS
 RESTRICTIONS:

 PROCEDURE:
	Splits !path into string array using delimiter which depends
	on the operating system, VMS or UNIX/ULTRIX.
 MODIFICATION HISTORY:
	RDB,	20-Mar-92	


WRT_HXTMVE_JCL $SSW/yohkoh/ucon/idl/bentley/wrt_hxtmve_jcl.pro
[Previous] [Next]
 NAME:
	WRT_HXTMVE_JCL

 PURPOSE:
	Creates JCL file for HXT image synthesis programme

 CALLING SEQUENCE:  
	wrt_hxtmve_jcl,flare_center,channel,comment

 INPUTS:
	flare_centre	HXT flare center (in unit of pitch, hxt coord.)
	channel		HXT energy channel  (0:L,1:M1,2:M2,3:H)
	comment		Comment field

 KEYWORD INPUTS
	jcl_name	Name of jcl file    (def is "jcl.list")
	infile_name	Name of input file  (def is "hxt_trn.dat")
	outfile_name	Name of output file (def is "hxt_image.dat")
	
	debug		If set, prints input parameters

 OUTPUTS:
	None
 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], concat_dir [4]
 SIDE EFFECTS:
	Produces a JCL file on the current directory
	Default name for this is "jcl.list"
 RESTRICTIONS:
	None

 PROCEDURE:
	Creates jcl file, using defaults when parameter is not 
	specified.

 MODIFICATION HISTORY:
	RDB  19-Jun-93	Written
	RDB  22-Jun-93	Added i/p, o/p, mod_profile and collimator sel.
			filename lines to JCL file. Keywords for i/p and
			o/p files. Quotes for comments, filenames
	MDM  22-Jun-93  Changed to use "para3.dat" file instead of "para_3"
	RDB  23-Jun-93	Corrected iter value to 0.10, was 0.01


WRT_HXTMVE_JCL3 $SSW/yohkoh/ucon/idl/sato/wrt_hxtmve_jcl3.pro
[Previous] [Next]
 NAME:
	WRT_HXTMVE_JCL3

 PURPOSE:
	Creates JCL file for HXT image synthesis programme

 CALLING SEQUENCE:  
	wrt_hxtmve_jcl3, flare_center, channel, comment

 INPUTS:
	flare_center	HXT flare center(X0,Y0)(in unit of pitch, 
                                hxt coord.) and FOV factor 
	channel		HXT energy channel  (0:L,1:M1,2:M2,3:H)
	comment		Comment field
 OPTION
       nodir ; do not write a full directory path. If the path name is 
                 too long, this option is needed

 KEYWORD INPUTS
	jcl_name	Name of jcl file    (def is "jcl.list")
	infile_name	Name of input file  (def is "hxt_trn.dat")
	outfile_name	Name of output file (def is "hxt_image.dat")
	
	debug		If set, prints input parameters
 USAGE
     wrt_hxtmve_jcl3,[X0,Y0,1.0],0, 'Good Imaging Tool',
                   outfile_name='nhxtmve.jcl'
     wrt_hxtmve_jcl3,[X0,Y0,1.0],0, 'Painful',
                   outfile_name='nhxtmve.jcl',/nodir

 OUTPUTS:
	HXT new JCL file using new imaging tool (J.Sato PhD Thesis)
 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], concat_dir [4]
 SIDE EFFECTS:
	Produces a JCL file on the current directory
	Default name for this is "jcl.list"
 RESTRICTIONS:
	None

 PROCEDURE:
	Creates jcl file, using defaults when parameter is not 
	specified.

 MODIFICATION HISTORY:
	RDB  19-Jun-93	Written
	RDB  22-Jun-93	Added i/p, o/p, mod_profile and collimator sel.
			filename lines to JCL file. Keywords for i/p and
			o/p files. Quotes for comments, filenames
	MDM  22-Jun-93  Changed to use "para3.dat" file instead of "para_3"
	RDB  23-Jun-93	Corrected iter value to 0.10, was 0.01
            03-May-98  J. Sato modefied for new HXT imaging tool and
                        set default parameters.

            01-Jun-98 J.Sato add NODIR option
                      (do not write actual directory)


WRT_MKBSD_CFL $SSW/yohkoh/bcs/idl/bsd/wrt_mkbsd_cfl.pro
[Previous] [Next]
 NAME:
	WRT_MKBSD_CFL

 PURPOSE:
	Creates .CFL file for F77 programme, MKBSD

 CALLING SEQUENCE:  
	WRT_MKBSD_CFL,filnam,istart,istop

 INPUTS:
	filnam		name of BDA file, including directory
	istart		start time - 7 element array in external format
	istop		stop time - 7 element array in external format

 KEYWORD INPUTS
	integration	Integration time      (def = 24. sec)
	nspectra	No. of Spectra        (def = 0)
	chans		Channels              (def = 1,2,3,4)
	count_level	Counter level         (def = 0)
	count_chan	Counter channel       (def = 4)
	offsets		Pointing offsets      (def = 0.,0.)
	consistency	Pointing Consistency  (def = 0.1)
	options		Programme options     (def = 1,1,0,0,0,0,0)

	cfl_name	Name of CFL           (def = yyy.cfl)

	debug		If set, prints input parameters

 OUTPUTS:
	None
 CALLS: ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], break_file [4]
 SIDE EFFECTS:
	Produces a .CFL file on the current directory
	Default name for this is YYY.CFL
 RESTRICTIONS:
	None

 PROCEDURE:
	Creates .CFL file, suing defualts when parameter is not 
	specified.

 MODIFICATION HISTORY:
	RDB, 24-Mar-92
	RDB, 05-Jun-92	Added CFL filename option
	RDB  15-Dec-92	Version 4 of CFL file...
	RDB   6-Jun-93	Added declaration of file written


wrt_x11_bitmap $SSW/yohkoh/ucon/idl/labonte/wrt_x11_bitmap.pro
[Previous] [Next]
  IDL routine to write out a byte array as an X11 bitmap

PRO wrt_x11_bitmap, array, filename

 Input:
	array = byte array, assumed to be 0 or 1
	filename = name of file to write to
 Use X11 command  xsetroot to load bitmap onto the root window.

   Written April, 1993   Barry LaBonte
 CALLED BY
	MK_ROOT_BITMAP


WrtDat2 $SSW/yohkoh/gen/idl/tape/wrtdat2.pro
[Previous] [Next]
	NAME: 
		WrtDat2
	
 CALLS: ***
	PREFIXCK, mt
	HISTORY:
		18-Nov-91, written, gal
		2-Mar-92, updated for prefixck w/0 obs file
		3-Apr-92, added option for data path
		8-feb-93, added a free/close statement on ioerror trap.
		9-feb-93, added error handler for error on close.
		6-Mar-93, corrected logic to handle files smaller than
			a single tape record.


WrtDat3 $SSW/yohkoh/gen/idl/tape/wrtdat3.pro
[Previous] [Next]
	NAME: 
		WrtDat3
	
 CALLS: ***
	PREFIXCK, mt
 CALLED BY:
	RdTap [1], RdTap [2], RdTap [3]
	HISTORY:
		Taken from Wrtdat2...rewrite of read/write loop logic.
		mods to wrtdat2 were as follows:
		18-Nov-91, written, gal
		2-Mar-92, updated for prefixck w/0 obs file
		3-Apr-92, added option for data path
		8-feb-93, added a free/close statement on ioerror trap.
		9-feb-93, added error handler for error on close.
		6-Mar-93, corrected logic to handle files smaller than
			a single tape record.
              24-Mar-94, (AKT) added check for whether ounit exists before closing


wrtsxtmap $SSW/yohkoh/gen/idl/reformat/wrtsxtmap.pro
[Previous] [Next]


 CALLS: ***
	GEN_STRUCT [1], GEN_STRUCT [2], RD_INDEX, REF_STRUCT, SXT_STRUCT, gt_day [1]
	gt_day [2], gt_time [1], gt_time [2], rdwrt [1], rdwrt [2], rdwrt [3]
 CALLED BY:
	mk_sd2, mk_sdl, mk_sl [1], mk_sl [2], mk_sot, mk_sxc, sav_sda [1], sav_sda [2]
	sav_sda [3], wrt1orbit [1], wrt1orbit [2]
OPTIONAL KEYWORD INPUT:
	shape_sav - If set, copy the shape_sav values to the roadmap
		    "shape_cmd" field (instead of the shape_cmd values)
		    This is needed because the roadmap field "shape_cmd"
		    is used to figure out the output array size.
	ndatabyte - If set, it is the number of byte in the data portion.
		    The older SDL, SLD, SLS, SOT, SXC and SXL files did
		    not have values written to the INDEX.GEN.NDATABYTES
		    value
HISTORY:
	Written Fall '91 by M.Morrison
	24-Aug-92 (MDM) - Added /shape_sav
	12-Jul-93 (MDM) - Added NDATABYTE and QDEBUG options
	 6-Dec-93 (MDM) - Added ROADMAP_IN option so that the full
			  roadmap does not have to be re-built when
			  appending to an existing file.
      19-Jul-2000 - S.L.Freeland - quieted an historical debug statement


wrttapdir $SSW/yohkoh/gen/idl/tape/wrttapdir.pro
[Previous] [Next]
	NAME:
		wrttapdir
	PURPOSE:
		Write an ASCII version of the SXT Tape Archive 
		directory file.
	INPUT:
		dhdr		header for dir file
		drecs		cpio data record info
		filename	dir file/tape name
		pathpre		path and prefix for filename
 CALLS: ***
	STR2ARR [1], STR2ARR [2]
 CALLED BY:
	RdTap [1], RdTap [2], RdTap [3], TapDir
	HISTORY:
		written by GAL 16-Sep-91
		added two fields after 1st and last file id.
		many additions late Nov. 91
		4-Dec-91, increased the format for integers output
			on sizes of tar files.
		14-Feb-92 changed tapename print
		17-Feb-92 changed data file table, added weekly table
			for obs log, pnt, etc.
		18-Feb-92 update for filename of tape dir. file
		20-Feb-92 update for new stru.
		26-Feb-92 added ck for 3/4 parameter in call
		3-Mar-92  increased number of bytes for tar file listings
			from 50 to 70 (see tar_size.pro)
		15-Apr-92 minor change for output format of data file 
			sizes.
		 4-nov-92 slf - file open logic, add rm -f 
		 6-Nov-92 MDM - corrected 4-Nov modification
		11-Jun-93 GAL - changed print statement for prefixes for
			weekly files.
               16-Nov-93 DMZ, EEE - handled vms delete case
			


wrttcplog $SSW/yohkoh/gen/idl/tape/wrttcplog.pro
[Previous] [Next]
	NAME: wrttcplog

	PURPOSE: write an entry to tape copy log file.

 CALLS: ***
	Bell, CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], concat_dir [4], def_tapd [1]
	def_tapd [2], def_tapd [3], get_host [1], get_host [2]
 CALLED BY:
	ACOPY [1], getm1ans, ycopy
	HISTORY: written 16-Apr-92, adopted from acopy.pro
                        25-Jan-92 (SLF) - force all tapenames same length
					   (ydb tape name different)
			  4-Feb-94 (SLF) - protect against tapename is bytarr
                         4-Jan-95 (SLF) - use point_lun instead of /append


wrttcplog_test $SSW/yohkoh/ucon/idl/slater/wrttcplog_test.pro
[Previous] [Next]
	NAME: wrttcplog_test
 CALLS:
 CALLED BY
	ACOPY_TEST


wrtwkdat $SSW/yohkoh/gen/idl/tape/wrtwkdat.pro
[Previous] [Next]
	NAME: 
		wrtwkdat
	PURPOSE:
		Read weekly files from cpio tape archive and write
		these files to disk.
	
 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], FILE_EXIST [2], STR2ARR [1]
	STR2ARR [2], concat_dir [4], file_exist [1], file_exist [3], mt
 CALLED BY:
	RdTap [1], RdTap [2], RdTap [3]
	HISTORY:
		written 27-Feb-92
		2-Mar-92, updated for new convention for obsid within
			load_recs.
		3-Apr-92, added dir path option
		26-Apr-93, added put_ydb switch option for creating 
			database.
		 6-May-93, bug fix on delfn: Initialized to null.
		18-Aug-93 (MDM) - Replaced references to DIR_SXT_DC
		14-Jun-94 (GAL) - updated log/env vars. for current
				list of weekly logs.


wSTDEV altered library procedure $SSW/yohkoh/ucon/idl/phillips/wstdev.pro
[Previous] [Next]
 NAME:
	wSTDEV   - altered library procedure.

 PURPOSE:
	Compute the standard deviation and, optionally, the
	weighted mean of any array.

 CATEGORY:
	G1- Simple calculations on statistical data.

 CALLING SEQUENCE:
	Result = wSTDEV(Array,weights [, Mean])

 INPUTS:
	Array:	The data array.  Array may be any type except string.

 OUTPUTS:
	STDEV returns the standard deviation (sample variance
	because the divisor is N-1) of Array.
		
 OPTIONAL OUTPUT PARAMETERS:
	Mean:	Upon return, this parameter contains the mean of the values
		in the data array.

 CALLS: ***
	WSTDEV
 COMMON BLOCKS:
	None.

 SIDE EFFECTS:
	None.

 RESTRICTIONS:
	None.

 PROCEDURE:
	Mean = TOTAL(Array*weights)/total(weights)
	Stdev = SQRT(TOTAL((Array*-Mean)^2/(N-1)))(* look this up....

 MODIFICATION HISTORY:
	DMS, RSI, Sept. 1983.
	ATP, ISAS, mar 1992