X
PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 06 Jan 2016 08:08 PM by  anon
Check if a File is being read in correctly
 3 Replies
Sort:
You are not authorized to post a reply.
Author Messages

anon



New Member


Posts:2
New Member


--
06 Jan 2016 08:08 PM
    I am new to IDL and working remotely with the author of a routine to understand why the routine works on his system and not on mine. We are using the same input files, the same routine, and the same commands to analyze asteroid spectra. He asked me to check if my IDL system was reading the input file (an asteroid spectrum) in correctly. How can I do this?

    Deleted User



    Basic Member


    Posts:143
    Basic Member


    --
    07 Jan 2016 05:18 PM
    I was wondering if you could please provide the following pieces of information: 1) Do you know at kind of data does this routine read? For example is it binary data, ascii, or images? 2) How is this routine provided to you? Was it provided to you as a save file or do you have the source code?

    Deleted User



    New Member


    Posts:2
    New Member


    --
    07 Jan 2016 07:46 PM
    The routine reads in two types of data...A txt file for the asteroid spectrum and four .dat files with mineralogy parameters, each for an individual composition. Not images or ASCII. The routine is a set of .pro files...Three files, written by the author....So, I assume it's source code.

    Zachary Norman



    Basic Member


    Posts:173
    Basic Member


    --
    08 Jan 2016 12:17 PM
    Hi Gordon, That really just depends on the data set that you are using for checking if it is being read correctly. If you want to make sure it is being read correctly, then you will probably need a reference data set to compare against. Your best bet would be to get a reference data set from your colleague and you can do this with an IDL save file. Here is an example for how to create an IDL .sav file which is what your colleague would do: SAVE, /VARIABLES, FILENAME = 'variables1.sav' That will save all of your variables into IDL's current working directory to the file calles variables1.sav. Alternatively you can save just one varibale into a .sav file with: SAVE, myarray, FILENAME = 'variables1.sav' Once you get the information from your colleague, you can restore the variables with the RESTORE procedure like: RESTORE, 'C:\Path\to\variables1.sav' -Zach (VIS)
    You are not authorized to post a reply.