Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
return logical value?

Subject: return logical value?

From: Lin

Date: 30 Mar, 2009 16:16:01

Message: 1 of 2

Hi all,

Say

c = {[1;0] [1;1]}

[i j] = find(c == [1;0])

It display an error that says,

??? Undefined function or method 'eq' for input arguments of type 'cell'.

Besides, can I output a logic '1', if [1;0] is found in c?

Thanks for helping.

Subject: return logical value?

From: Steven Lord

Date: 30 Mar, 2009 17:00:13

Message: 2 of 2


"Lin " <shenqlv@yahoo.com> wrote in message
news:gqqr81$3ou$1@fred.mathworks.com...
> Hi all,
>
> Say
>
> c = {[1;0] [1;1]}
>
> [i j] = find(c == [1;0])
>
> It display an error that says,
>
> ??? Undefined function or method 'eq' for input arguments of type 'cell'.
>
> Besides, can I output a logic '1', if [1;0] is found in c?
>
> Thanks for helping.

Use CELLFUN with ISEQUAL.

--
Steve Lord
slord@mathworks.com

Tags for this Thread

No tags are associated with this thread.

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us