![]() Repeat this for all the lines in the file, each time making a new wave. For each item call str2num and store it in the wave. For increased speed you can try looping over the string directly, though whether it's faster or not is hard to predict. Note that this is not very efficient but it should get the job done. Use StringFromList ( j, lineContents, " " ), where 'j' is the second loop counter. ![]() Then set up another for loop inside the first one that loops over all the items. Allocate a wave with the appropriate number of points. Subtract 2 from this to avoid counting the two header entries (or you can parse them if you like). Inside the for loop, get the number of entries in each line by calling ItemsInList (lineContents, " " ). Set up a for loop that calls FReadLine refNum, lineContents and breaks when FReadLine returns the empty string (lineContents is the name of a string variable that you declare). I assume someone from WaveMetrics will chime in on that. I'm not sure if the built-in LoadWave and friends can handle this natively. # Date_Time Iterationĝata (4000 points at 100.000000Hz).ěefore Precession = 52 s. the date/time in the format yyyy-mm-dd_hh:mm:ss.ddd_UTC Each line after the header is the equivalent of one wave, starting with There are 5 header lines I would like to ignore, except that I do want to take the run number (line 3) from it to use as a prefix for the wavenames I would be extremely grateful if someone here would help me figure out how to read in this data! I wasn't involved in the format schemes and have no control over them. I'm working on a project where data is generated for many different systems and while I have been able to manage with most of the files, this one format (shown below) has me stumped. Wide-Angle Neutron Spin Echo Spectroscopy.Then do the HDF5 Guided Tour in the HDF5 Help file. To install the HDF5 package, run Igor, choose Data->Load Waves->Packages->Install HDF5 Package. To try Igor's HDF5 package, you need Igor Pro 5.04 or later or the Igor Pro demo, version 5.04 or later. Save Igor data to HDF5 groups, datasets, and attributes.Load groups, datasets, and attributes into Igor.Igor's HDF5 package adds operations that you can invoke from Igor's programming environment. ![]() Igor's HDF5 package supports the "HDF5 Image and Palette Specification" version 1.2.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |