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: How to Select Entire Row From Excel File Uisng Prompt?
Replies: 11   Last Post: Nov 23, 2012 5:52 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
ryanshuell@gmail.com

Posts: 114
Registered: 2/11/08
Re: How to Select Entire Row From Excel File Uisng Prompt?
Posted: Nov 20, 2012 9:54 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Yeah, I missed that typo thing. Well, I'm trying this now; still not working:

requiredDateNumber = '11/2/2012';

data = xlsread('C:\Program Files\MATLAB\R2012a\Symbols.xls');
rowIndex = (data(:,1) == requiredDateNumber);

if any(rowIndex)
rowData = data(rowIndex,2:end);
else
error('There is no corresponding row.');
end

Error using ==
Matrix dimensions must agree.

Error in Read_Specific_Row (line 34)
rowIndex = (data(:,1) == requiredDateNumber);


I did some research on this. I can't figure out what the problem is. Yes, I'm sure 'Matrix dimensions must agree', but what are these Matrix dimensions?????


"Phil Goddard" <phil@goddardconsulting.ca> wrote in message <k8f5u1$5vd$1@newscl01ah.mathworks.com>...
> Note that there is also a typo.
>
> In one place I have
> requireDateNumber.
>
> It should be
> requiredDateNumber.
>
> Phil.




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.