Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: matlab program
Replies: 1   Last Post: Dec 9, 2012 10:55 AM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
dpb

Posts: 8,208
Registered: 6/7/07
Re: matlab program
Posted: Dec 9, 2012 10:55 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

On 12/9/2012 4:20 AM, Nsengimana Cyprien wrote:
> Hello matlab users,does someone know how to solve this question?
> I would need to make a program that can be able to read [filename.mat]
> with 48 rows of data observations with 6 columns.The program should be
> able to read two consecutives data lines(i.e two rows of data set) and
> jump the 3rd row everytime and continue to do so untill all data matrix
> of 48 rows and 6 columns are done.This will help me to separate data
> samples into two main groups .i.e 2 training data set and one validation
> data set continuously untill all data are finished to be read.


Much impler to just read the whole array and then delete the unwanted
rows...

x=textread('yourfile'); % Yes, deprecated but still easy and useful
x(3:3:end,:)=[];

--



Date Subject Author
12/9/12
Read matlab program
Nsengimana Cyprien
12/9/12
Read Re: matlab program
dpb

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.