General function to write text files with selected waves and variable sperators
I am trying to write a general function to write to a text a row of comma or tab or colon etc separated variables from a selection of 1d waves of the same length. I have done this for a fixed number of waves with the wave references hard wired into to the code. The fprintf operation has enough flexibility to specify the format needed. But I cannot see a way of doing this with a user specified number of waves. My thoughts have been to build a text wave with the strings containing the names of the waves to be output, and then put it in a loop to set up the wave referencing for each wave. But I can't see how to do using straightforward wave referencing. I have considered perhaps using duplicate or make to set up dummy waves in the function and deleting them at the end but this seems very clunky. I also think I could probably do it in a macro ... any advice welcome
--
J. J. Weimer
Chemistry / Chemical & Materials Engineering, UAH
October 26, 2017 at 11:03 am - Permalink
October 26, 2017 at 01:38 pm - Permalink
October 26, 2017 at 02:16 pm - Permalink
October 28, 2017 at 07:14 am - Permalink