QUOTE (Kevin P @ Mar 11 2008, 02:45 PM)
That's it isn't it?
Sometimes all it takes is a gentle nudge in the right direction :worship:
Thinking about it in a different way: If I had a resolution 1mm x 1mm then my location would be the same as the index in the array I wanted to populate (assuming I rounded all the data to the nearest mm and normalised it all to a suitable zero). So If I want to change the resolution all I need to do is normalise the data to a suitable starting point by subtracting a constant (essentially making the top left position = 0,0) then divide each value by my resolution to give me the index of the value in the population density array I need to increment.
Many, many thanks!
***
With regards to my initial query about keeping a VI running while i played with the data and not having to load the data again, I sorted that out with a while loop.
But I now have a related question:
Once you stop a while loop and pass the data out of it how do you make it run again?
The VI i've posted below opens a file, plots the data then lets me choose the timescale and select the data I want to keep. As soon as I stop the loops where i choose the timescale and select the data then the data is saved and the VI stops.
How do I keep it running so I can make a different selection of data?
As it is, it's ok for a run where I use one tracer, but it's not inconceivable that I could put numerous tracers through the reactor one at a time and save all the data to the same file (saving data for each tracer seperately at the time of the run is not an option unfortunately). I would then need to look at the plot, select the data corresponding to the first tracer, save to a file, then select the data for the 2nd and save again etc. How would I do this? I've tried using while loops in various ways but I can't get it to do what I want.