11-27-2017 02:06 PM
11-27-2017 02:31 PM
@sup_1993 wrote:
2. However In the excel sheet I require a format of 20 rows (number of analog channels) and 500 columns (number of samples).Note that, I am able to record 500 columns, the number of rows is not equal to 20 and depends on my time target.
Normally you want your channels to correspond to the columns. Then as you append the data, it keeps adding to the channel's waveform data. So you really want 20 columns and 500xN rows, where N is the number of iterations of this loop you run.
11-28-2017 02:33 PM - edited 11-28-2017 02:33 PM
I have to agree with crossrulz on this one. In over 30 years in the industry I have never been asked to put data in a spreadsheet with the channels in rows and the measurements in columns. That just makes no sense at all.
But if you are sure that is what you want, try the Transpose Array function to swap the rows and columns in your array
11-28-2017 02:56 PM
Yes, I have already used a transpose function in my code to exchange the rows and columns.
I require the format (i.e, channels in the rows) as that's how the csv file is read in MATLAB (which is next stage of the project; existing file).