You are here: IRS>SmartDoc Web>HiResSpectralMapping (30 Oct 2008, WikiGuest)

SMART Cook Book

Hi-Res Spectral Mapping ("Step and Stare")

Usage

This recipe assumes that you have IRS high resolution data (Short high or long high modules) taken in spectral mapping mode. (Formerly called "step and stare" mode).
It assumes that you have multiple exposures taken in a series of "steps" (of slightly differing RA & Dec.) across a given source.
The result will be a series of full end-to-end high resolution spectra output into a text or ".fits" file that can be imported into a different plotting/text processing program for publication.
This recipe does not include the subtraction of nodding observations (which are not currently used in spectral mapping mode) nor is any instruction provided as to curve fitting multiple spectra (eg. to a Gaussian) to estimate an intensity distribution across the source. Either or both of these instructions may be provided later.

|Note : |SMART has a large number of buttons, reflecting its multiple functionality. This recipe only specifically refers to those buttons actually used for this particular processing.
Any buttons not referred to do not need to be used here and may be safely ignored. |

To extract an observation do the following :

  1. SMART must be installed or accessible on the machine you are using. This machine must have a windowing system (eg. X-windows) running.
    (Check with your system administrator if you need either SMART and/or windowing installed.)
  2. Invoke SMART. This can be by typing "smart" or "smart-cvs" at the prompt.
    (Check with your system administrator which configuration of SMART you have installed and how you need to invoke it.)
    Some messages will scroll past the prompt. This is normal. Then the Project Manager window will appear, headed "SMART Project".
  3. All work in SMART is organized into "Projects". You can start a new project (step 4) or add to an existing one (step 5).
  4. To start a new project :

    1. Click on "Project" and then select "New" on the drop-down menu that appears.
    2. A box appears called "New Project".
    3. At "New Project Name:" type in a new project name (eg. "Project1") and click "OK".
    4. The new project window will disappear and a new project will be created in SMART.
    5. An entry "Dataset1" will appear in the "Project Manager" box.
  5. To add to an existing project :

    1. Click on "Project" and then select "Load" on the drop-down menu that appears.
    2. A selection window will appear headed "Please Select a File".
    3. You can navigate between different directories using the "Directories" and "Filter" boxes.
    4. To select a file click on it. It will highlight. All SMART projects have a ".smp" extension.
    5. Then click "OK" on the selection window.
    6. The selection window will disappear and the selected project will be loaded into SMART.

      Note : NOTE: Depending on the project size SMART may take 1-2 minutes to load it. Messages will scroll at the prompt during loading. This is normal.

    7. The Project Manager will display a list of current datasets in the project. Click on the one you want to add data to and it will highlight.
    8. Alternatively you can add a new, empty dataset by clicking on the "Add Dataset" button at the bottom of the Project Manager.
      A pop-up window will appear headed "New Dataset". Type in a name (eg. "Dataset42") and click "OK".

      Note : Within SMART you can only work on one dataset at a time.

  6. Click on the dataset you want to work with and it will highlight.
    If this is the first time since starting SMART that a dataset has been highlighted then another row of buttons will appear at the bottom of the window.
  7. Click the "Add Records/Edit Dataset" button. A new window will appear headed "Dataset:Dataset1".
  8. On "Dataset:Dataset1" click "Browse". A selection window will appear headed "Please Select a File".

    Note : File naming conventions and locations for SIRTF/Spitzer data are not controlled or explained by SMART. SMART can accommodate any file naming convention applied. Users may obtain data files directly from SSC, from the SIRTF/Spitzer Public Archive of from their own site specific data storage. Please see your own site or system administrator for help with this.

  9. Select the data file(s) for processing. You can navigate between different directories using the "Directories" and "Filter" boxes.
    To select a single file click on it. It will highlight. Then click "OK" on the selection window.
    Multiple entries may be selected from the list in several different ways :

    1. Continuous block - click on the first required entry to highlight it and then drag the cursor arrow downwards with the mouse button still pressed until the last required entry is reached.
      The entire block will highlight. Then click "OK" on the selection window.
    2. Continuous block (alternative) - click on the first required entry to highlight it and then scroll down with the "down arrow" key while the "Shift" button is pressed.
      Keep scrolling down until the last required entry is reached. The entire block will highlight. Then click "OK" on the selection window.
    3. Continuous block (alternative) - click on the first required entry to highlight it then move the mouse pointer down and click on last required entry while the "Shift" button is pressed.
      This will select whole block and may be faster than using the down arrow in some cases. Then click "OK" on the selection window.
    4. Discontinuous block - First use one of the above methods to highlight the entire range from first to last.
      Then de-select unwanted entries by moving the cursor to them and clicking the mouse with the "Ctrl" (control) key pressed.
      Multiple entries within a block selection may be de-selected by either :
      1. Multiple individual clicks with the mouse button and "Ctrl" still pressed. (Useful for removing scattered individual entries.)
      2. Dragging the cursor arrow downwards with the mouse button and "Ctrl" still pressed until the last required entry is reached. (Useful for removing blocks.)
      Then click "OK" on the selection window.
    5. Discontinuous individual entries - Select one by one by clicking with the mouse with the "Ctrl" (control) key pressed. Then click "OK" on the selection window.
  10. The selected file(s) will appear listed in the "Dataset:Dataset1" window.
  11. If necessary you can change any file name (within SMART) by clicking on it to highlight it. Then click the "Rename" button at the bottom of the "Dataset:Dataset1" window.
    A small window headed "Rename" appears. Enter the new file name in the "Rename" window and then click "OK".
    This will return you to the "Dataset:Dataset1" window with the file renamed.
  12. Select a file to be extracted. Click on it and it will highlight.
    You can select two or more files for extraction together by highlighting all of them.
    Multiple highlighting in the "Dataset:Dataset1" is done in exactly the same way as for the file selection box described in step 9.
  13. Click on the "Extract" button. (Bottom row of buttons on the "Dataset:Dataset1" window.)
  14. A new window appears headed "Extraction ...".
  15. Under "Select Extraction Type:" click on "Full/!NoSkySub". (This is the default.) Then click "OK".

    |Note : |"Full/!NoSkySub" is the only extraction type currently available for high resolution spectra.
    It produces the spectrum arising from all flux contained in the full five pixel height (perpendicular to dispersion) of the high resolution slit.
    There is no background subtraction with this option.
    If there is a significant background underlying the source, other methods have to be used to subtract this background, such as having an independent "sky" spectrum for subtraction. |

  16. Messages will scroll at the prompt. This is normal.
  17. A large window will appear titled "SMART-ISAP:ISO/SIRTF Spectral Analysis Package". This is the IDEA window.
    At its center is the display box where extracted data is displayed and can be worked on.
  18. Above the display box are a group of radio button lists titled "BCD:", "Order:", "Slit Pos:" and "Module".
    For the "Order:" list click on "All".
  19. If two or more files have been selected for extraction together then they will be listed separately on the "BCD:" radio button list.
    You can select "All" to display them all simultaneously or choose an individual BCD number to just display one dataset.
    Make sure you know which dataset is which.
  20. Then click the "Plot" button on the left hand side of the IDEA window. The extracted data will appear in the display box as a set of data points.
  21. Click on the "Style" button on the left hand side of the display box. A new window will appear called "Plot Style Preferences". In the top line of this ("Line Style:") click on "Connected".
    Then click on the "Apply" button at the bottom left hand corner. The "Plot Style Preferences" window will disappear.
  22. WARNING : If you decide not to use or leave a particular window, (here "Plot Style Preferences"), always leave by clicking on its "Cancel" or "Quit" button
    and NOT by clicking on the "X" in the upper right hand corner. Clicking the "X" can cause unpredictable results.
  23. OPTIONAL STEP - color Some users find it helpful to have the different orders displayed in different colors. To do this click on the "Style" button on the left hand side of the display box.
    A new window will appear called "Plot Style Preferences". In the second line of this ("Color Coding Preference:") click on "Order Number".
    Then click on the "Apply" button at the bottom left hand corner. The "Plot Style Preferences" window will disappear.
  24. Extracted data now appears in the IDEA Window display box as connected data points.
    (Each order will also be colored differently if you have selected this above.)

    Note : If your data suddenly has one order missing it may be that one of your default colors is black. See your system administrator to change this.

  25. The full spectrum can appear very ragged due to poor calibrations at the edges of each order.
    Any part of the spectrum can be enlarged for examination by holding down the left mouse button and drawing a box around the area for examination.
    When finished click "Plot" again to return to the full spectrum.
  26. It is often helpful to trim the edges of each order as the first and last few data points of each order may be misleading.
    To do this first go to the "Orders" list on the IDEA window above the main display box. Unselect "All" and select the first order only.
    Then click "Plot" on the left hand side of the IDEA window.
  27. This will display just the first order. If there is significant rise or drop at either/both edges of the order it can be masked out.
  28. With the right mouse button draw a box around the portion of the edge of the spectrum you want to mask out. A window headed "Applications" will appear. Click on "Mask".
    The "Applications" window will disappear and in the main display box selected portion of the order will be masked out. Repeat for the other edge of the order if needed.

    Note : The data may be automatically re-scaled to best fill the display box. IE. Its appearance may change. This is normal.

  29. If you do not like a particular box you have selected click on "Cancel" at the right hand side of the "Applications" window (which will disappear) then click "Replot" at the bottom right of the IDEA window. This will remove the box you have drawn and you can draw another.
  30. At any time you can recover data points that have been masked. To do this on the IDEA window click "All" on the "Orders" list, then "Plot". This ensures that all the data is displayed.
    Then with the right mouse key draw a box around the entire display box area within the displayed axes.
    When the "Applications" window appears click "!UnMask". This will restore the masked data to the display box.
  31. If you are absolutely sure you will NEVER need the edge data points then instead of selecting "Mask" on the "Applications" window select "Zap" instead.
    The "Zap" function works in the same way as "Mask" however any data removed with it is gone permanently from the extracted data.
    It cannot be recovered or re-viewed later.
  32. For each order (11-20) repeat steps 26-31 until all unwanted order edges have been removed.
  33. Once you are satisfied that all unwanted data has been trimmed again click on "All" on the "Order" list. Then click on "Plot".
    This will display the full extracted spectrum with unwanted data removed.
  34. At the top right of the IDEA window there is a row of buttons. Click the fourth one. "Store-Prime".
  35. On the IDEA window left hand side click the "Store" button.
  36. A new window will display headed "Stored Data Sets".
    This displays a radio button list of all current datasets being worked on.
    The first entry will be the name of the original file extracted. The second entry will be the same name preceded by a row of "M:", "Z:" etc. Each letter represents one "Mask" or "Zap" operation performed.
    EG: 1st entry - IRAS_12345+6789 2nd entry - M:M:Z:IRAS_12345+6789 (ie. original data with 2 Mask and 1 Zap performed on it.)
  37. It is usually more convenient to give the processed data some other, more meaningful and less cumbersome name.
    To do this on the "Stored Data Sets" window select the dataset to be renamed. Then click on "Apply Function to :[filename]" at the top of the "Stored Data Sets" window. A sub-menu will appear, click on "Change Name".
  38. A small pop-up window will appear. At "New Title:" enter the new name. Then click "OK".
    The "Stored Data Sets" window will then disappear.
  39. Click the "Store" button again to display "Stored Data Sets".
    The re-named dataset will appear listed with its new name. Select it.

  40. Click on "Apply Function to :[filename]" at the top of the "Stored Data Sets" window. A sub-menu will appear, click on "Write to disk in...".
  41. Another sub menu will appear with three options :

    1. FITS format - the standard ".fits" table format.
    2. ASCII format - This leads to 2 further options :
      1. Write the header + All the data An ASCII file of data in column format containing all data in the dataset.
      2. Write the header + wave flux stdev and flag data An ASCII file of data in column format containing the minimum data needed for re-loading into the IDEA window at a later time.
    3. ISAP-XDR format - The IDL "XDR" format. Only use this to save data you intend to further process ONLY with other IDL programs.
  42. Select one of the save options. The choice of format will be determined by the input requirements of any piece of software you intend to use next.
    A small pop-up window will appear. At "Name for [type] file" the default name displayed is the current name for the dataset within the IDEA window.
    The default directory is the one from which SMART was invoked. You can change either of these by typing in "directory/file".
    (Please use absolute path names for directories.)Then click "OK". The entry window and the "Stored Data Sets" window will then disappear.
  43. At this point you have extracted and stored the first spectra of the spectral map.
  44. To extract and store each of the other spectra from this observation repeat steps 12-42.
    When the second and subsequent datasets have been extracted a small window will appear headed "Acknowledge" with the message "Updating stored data sets with newly extracted data". Click "OK" on this window.
  45. Multiple datasets can be held within the IDEA window. However only one can be worked with at any one time.
    The dataset being worked with is called the "Prime" dataset. The first dataset to be extracted is automatically made the prime dataset.
    Running a second or subsequent extraction does not change this. The first extracted dataset remains the prime dataset until it is specifically changed.

    Note : In step 34 above when "Store-Prime" is clicked this takes the masked/zapped version of the first dataset and creates a new separate dataset composed of that data. This new dataset then becomes the prime dataset.

  46. To make a second or subsequent extracted dataset the prime one click on "Store".
    The "Stored Data Sets" window will appear with a list of all datasets. Click on the one you want to make prime. (IE. work on at that time.)
  47. Then click on the "Apply Function to: [filename]".
    On the sub menu which appears click "Make Prime". The selected dataset will then become the prime one.
  48. This may cause the display box to go blank. The new prime dataset may well have some different configuration of orders from its predecessor.
    If this happens click "All" on the "Orders" list near the top of the IDEA window, then "Plot" on the left hand side. This will display the new prime dataset in the display window.
  49. This recipe does not include the subtraction of nodding observations (which are not currently used in spectral mapping mode) nor is any instruction provided as to curve fitting multiple spectra (eg. to a Gaussian) to estimate an intensity distribution across the source. Either or both of these instructions may be provided later.
  50. When finished click the "QUIT" button at the bottom left of the IDEA window.
  51. A small window will appear headed "ISAP Exit", displaying the text "Do you really want to exit?". Click "Yes".
  52. A small window will appear headed "Update Project", displaying the text "Do you want to save your spectral data to the SMART Project Manager?". Click "Yes".
  53. In the "Dataset:Dataset1" window a new entries will appear in the file list. These are the extracted and modified spectra you have just made.
    They will be named with the name(s) you gave to them in the IDEA window. They will be stored in this SMART project for further use. It will not be necessary to extract them again.
  54. If necessary you can change any dataset name within SMART by clicking on it to highlight it. Then clicking the "Rename" button at the bottom of the "Dataset:Dataset1" window.
    A small window headed "Rename" appears. Enter the new file name in the "Rename" window and then click "OK". This will return you to the "Dataset:Dataset1" window with the file renamed.
  55. On the "Dataset:Dataset1" window click "Close".
  56. On the Project Manager" window click "Exit".
  57. A small pop-up window headed "Question" will appear asking "Save Project ? [project name]. Click "Yes".
  58. You have now left SMART.
  59. IDL is still invoked at the prompt. Type "exit" at the prompt to leave IDL.

 
This site is powered by FoswikiCopyright © 2002-2009 by the Cornell IRS Team.
Send feedback. We use Foswiki.