Prev: Calculating the distance between an object and our camera
Next: integer programming with matlab
From: Randi Price on 27 May 2010 13:48 Hi, thanks in advance for your input. I'm a super newbie Matlab user, so also thanks for your patience! :) I have a collection of data files: "z.txt" that are x,y pairs. The x column in each data file is the same. I have written a program that will choose a particular x value. I need to find the y value for that x in each z.txt file and make a new array that is y vs. z. Then I want to be able to do this with many x values and save all the y vs. z arrays for each x to the same file. Ex: 100.txt: 0.10,0.44 0.20,0.32 0.30,0.68 0.40,0.84 0.50, 0.24 0.60, 0.47 200.txt: 0.10,0.87 0.20,0.53 0.30,0.29 0.40,0.32 0.50, 0.63 0.60, 0.11 Convert this to... "0.20".txt: 100, 0.32 200, 0.53 "0.40".txt: 100,0.84 200,0.32 etc... Btw, if it matters there are about 1000 x,y pairs in each z.txt file, and there are about 20 z.txt files. I would like to be able to choose ~20 x values. The output files x.txt should be able to be imported into Excel or SigmaPlot. Thanks so much!
|
Pages: 1 Prev: Calculating the distance between an object and our camera Next: integer programming with matlab |