THM_GUI widget definitions: MAIN WINDOW: Starting from the left, the first column of buttons (under "Data Choices") on the left side are used to choose different kinds of data to load, to choose the time range for the data, and to load the data. There is a button for each inetrument, a button for thime range selection and a button which initiates the loading process. Each of these buttons (except for the load button) will pop up a selection widget. The buttons across the top in the middle are for data calibtration, coordinate transforms, data processing and plotting. When clicked, each of these buttons pops up a widget for different data manipulation tasks. In the middle of the window there are windows which show the data sets that have been selected and the history. On the bottom of the main window there is a one-line progress widget that informs the user about the status of the current data lodaing or processing. also there are "STOP", "HELP","Error", "Config" and "Exit". The STOP button should stop the current process and return control to the master GUI. The HELP button pops up a text widget that shows this text. The Error button pops up a widget with the THEMIS help request form, that can be edited, saved and emailed. The Config button pops up a widget that allows the user to set different parameters in the !themis system variable that control automatic downloading. The Exit button ends the program. WINDOWS, BUTTONS AND POPUPS: LOADED DATA WINDOW: When data is loaded, information appears in the window, for each datatype loaded, the appropriate variable name and time range are listed. To choose a particular data set for plotting, or other processing, left-click. Multiple data sets can be selectd by holding the "control" key, and clicking more than one. Also, you can click on an option, then hold "shift", and the left mouse button, and drag the cursor over the other data sets. Each of these data sets currently includes one "tplot variable", which can be processed and plotted using the IDL program TPLOT. Note (and this is important): The data set that you click on in this window is called the "active" data set. Any coordinate transform, data processing or plotting task will refer to this data only. If you have loaded data, then the "active" data sets are those which have been loaded most recently. Often a data processing task will change the active data set to be the data that has been just been created. When you are in doubt which is the active data set, click on it and it will be set. In the window, the active data sets are shown with "-->" before the variable name. CHOOSING DATA USING STRINGS: Just below the Loaded data window is a window in which the user can type in a string (or a set of strings separated by spaces) and set the active data sets to the variables including those strings. For example, typing in "tha_spin* tha_fg*" (don't include the quotes in the actual window) will set the active data sets to all variables that start with the string "tha_spin" and also all variables with names starting with the string "tha_fg". the question mark can be included as a wild card for single characters:, e.g., "th?_spin*", will return all variables with "th" then one letter, then "_spin*. Once the string is typed, click on the "Set Active Data to String" button. HISTORY WINDOW: This is a list of the IDL commands which have been used, and error messages. Just below the history window are buttons that allow the user to save the history in a file, and clear the history. The "Save History" button will save the history in an IDL source file called "thm_gui_yyyymmddss.pro" in your local working directory. The time stamp on the file is the local system time. The "Clear History" button deletes the history. Since this includes error messages, it is hoped that users will save and email this file when errors occur. PROGRESS WINDOW: In this window, there is a line of text that tells the user what is happening, with respect to data loading and processing tasks. If there is an error, then this will display the string "Error - See History:" to alert the user to an error. DATA QUANTITY SELECTION BUTTONS: Each data quantity selection button pops up a widget that show the different types of data that can be loaded for that instrument. For ground-based data the list on the left gives the different ground stations that are available. For spacecraft data, the choice is of the different probes. To choose data from that station/probe, click on it. Multiple stations/probes can be selectd by holding the "control" key, and clicking more than one. Also, you can click on an option, then hold "shift", and the left mouse button, and drag the cursor over the others. Clicking "*" will select all available ground stations or probes. The types of data that are available are listed in the middle, for level 1 data, and on the right for level 2 data. Click on the type of data to choose it, multiple selections and "*" are handled in the same manner as the choice of ground station or probe. On the bottom, there is a place to type in a string for the data selection, the data types that match this string are then displayed in the list windows. Wild card characters are necessary. If for example, you are selecting state data, and you wanted all data types that include "spin", then you type "*spin*". Note that you still need to click on something in the list window to choose the data, even if ther is only one variable available. When you are done, click the "Accept and Close" button to exit the popup. TIME RANGE SELECTION BUTTON: Choose Start Time: Pops up a widget that allows you to choose a start time for data to be loaded. You may also type a string value of the form yyyy-mm-dd/hh:mm:ss in the window next to the button. Choose End Time: Pops up a widget that allows you to choose an end time for data to be loaded. You may also type a string value of the form yyyy-mm-dd/hh:mm:ss in the window next to the button. When you are done, click the "Accept and Close" button to exit the popup. LOAD DATA BUTTON: Click on this button to load the selected data. All selected datatypes will be loaded. CALIBRATION BUTTON: Clicking on the "Calibrate Data" button pops up a widget with buttons for different instruments. Currently, EFI, FBK, FGM, FIT, MOM are supported. When you click on one of these buttons, the calibration procedure will be performed for whichever instrument is chosen. Click "Done" to exit the popup. COORDINATE TRANSFORM BUTTON: When the "Coordinate Transform" button is clicked, a popup appears with different choices for corrdinate transforms. Click on a "From" button and a "To" button to define the transform that you want. Click on the "transform" button to perform the transform. Click on the "Done" button to dismiss the popup. Unlike the calibration button, which will go and find the appropriate data to process, for this button you need to have set an "active" data set by clicking it in the Loaded Data window. DATA PROCESSING BUTTON: When the "Data Processing" button is clicked, a popup appears with various opitons for data processing. SUBTRACT AVERAGE: For each data set, the average value is subtracted. new variables are created, with the syntax: new_var = old_var+"-d", and the new variables become the "active" data sets. SUBTRACT MEDIAN: For each data set, the median value is subtracted. new variables are created, with the syntax: new_var = old_var+"-m", and the new variables become the "active" data sets. SMOOTH DATA: Boxcar smoothing of the data. A widget will pop up, asking how many data points to smooth over. Choose a value, and click on "accept and close". The default is 11 points. New variables will be created, with "_sm_npts" appended to the old variable names, where npts is the smoothing resolution. TIME AVERAGE: Click this button to average that data over time, a window will pop up, if you want to change the time resolution, the default time resolution is 60 seconds. New variables will be created, with "_av_tres" appended to the old variable names, where tres is the time resolution. CLIP: Clips data above and below a set maximum and minimum, a widget pops up which allows these values to be set. Then data outside the range is set to NaN. New variables will be created, with "_clip" appended to the old variable names. DEFLAG: Interpolates or repeats the most recent valid data value over gaps in the data (gaps are denoted by NaNs). A window pops up which is used to set the method, there are two choices: "repeat" will repeat the last good value over the gap. "linear" will interpolate over gaps. (Probably the text widget will be replaced with buttons.) New variables will be created, with "_deflag" appended to the old variable names. CLEAN SPIKES: Removes spikes from messy data. New variables will be created, with "_dspk" appended to the old variables. TIME DERIVATIVE: Take the time derivative of the active data sets. New variables will be created, with "d_" prepended to the old variable names. WAVELET TRANSFORM: The data is split into components, and a basic wavelet transform is performed on each component, with "_wv" appended to the old variable names. DPWRSPC: The data is split into components, and a dynamic power spectrum is obtained from each component, with "_dpwrspc" appended to the old variable names. TIME LIMITS: A popup will appear, allowing the user to set time limits for the processing application, either by using the cursor on the existing plot window, or by typing the limits directly, or using a time selection widget. RENAME: A popup prompts the user for the new variable name for each of the "active" data sets, and each variable is renamed to the new name. SAVE: An IDL save file is created with all of the active data sets. A filename selection window is popped up, and the user can change the default filename. SAVE ASCII: The active data sets are saved in ascii files in the current working directory. DELETE: The active data sets are deleted. DONE: Click here to close the widget. PLOT DATA BUTTON: PLOT TYPE: click on "SCREEN" for screen plots. If you click on "PNG" a png plot will be created when you click the "Draw Plot" button, with filename = "thm_gui_plot_yyyymmddss.png" in your local working directory. The time stamp on the file is the local system time. DRAW PLOT: click here to draw the plot. YLIMIT: Set the y limits of the active data sets. A text widget pops up, allowing the limits to be set, and also log plotting can be set/unset. ZLIMIT: Same as Ylimit, for the Zlimits for spectrogram data. SET/UNSET SPECTROGRAM: Pops up a text widget. if set to 1, then the active data is set to be plotted as a spectrogram, if set to 0, then line plots. (Should be changed to buttons.) SET PLOT WINDOW SIZE: Pops up a widget for the window size. For screen plots you can just drag the window for resizing. The set plot window size window can be used to set the window size for png plots. SET PLOT WINDOW NUMBER: Sets the window number for the screen plots. SET TIME LIMITS: A popup will appear, allowing the user to set time limits for the processing application, either by using the cursor on the existing plot window, or by typing the limits directly, or using a time selection widget. DONE: Click here to dismiss the widget. HELP BUTTON: Clicking on the "HELP" button displays this file. ERROR BUTTON: When this button is clicked, an editable text widget pops up which display the THEMIS Science Help Request Form. This allows the user to input information about the error which has occurred. There is a save button, which saves the request in a file, which can be emailed to THEMIS_Science_Support@ssl.berkeley.edu. Click "Done" to dismiss this widget. IMPORTANT NOTE: This error widget also pops up automatically when processing errors occur -- the Error button should only be needed if everything else fails. CONFIG BUTTON: This button pops up a widget that allows access to the !themis system variable that controls the automatic downloading process. You can type in values for the different options in the windows. The top window gives the local data directory. Any THEMIS data downloaded is expected to be downloaded into this directory. The default value for users who are logged on to an ssl.berkeley.edu machine is "/disks/data/themis/". For windows users, the default value is "C:/data/themis/". It can be set to any directory for which the user has write permission. The second window shows the remote data directory. The default is "http://themis.ssl.berkeley.edu/data/themis/" Next is the flag for automatic downloads; set this to 0 for automatic downloads, 1 for no automatic downloads. (This should be set to 1 for local SSL users). Next is the flag for file updates, if set to zero this will update files in local data directories if there is a file in the remote data directory which has the same name, but is new. If set to 1, then this is not done. Next is the download only flag; Set this to 0 to download and load data, set to 1 to only download data, and not load. Last is the verbose flag, set this to a number from 0 to 10. The higher the number, the more messages you get during processing. RESET: If you press this button, the configuration is returned to the state which existed before you popped up the widget. RESET TO DEFAULT: If you press this button, the configuration is returned to the default state in THM_CONFIG.pro, and any saved configuration file is deleted. SAVE: If this button is pressed, then the current configuration is saved in a file. This file ends up in a directory created by the IDL APP_USER_DIR routine, on a windows system the path looks like this: "C:\usernme\.idl\themis\thm_config-4-win32\thm_config.txt". On a linux machine, it looks like: "$HOME\.idl\themis\thm_config-4-linux\thm_config.txt" IMPORTANT: Once you have saved this file, it will always be read when you run any THEMIS routines -- you should only need to do this once for each operating system that you are using. EXIT BUTTON: Exits the program.