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:
How to get rid of obsolete function warning

Subject: How to get rid of obsolete function warning

From: Elnaz

Date: 8 Apr, 2013 23:54:10

Message: 1 of 4

Hi all,
Since I'm using randint function I receive:
Warning: This is an obsolete function and may be removed in the
future.
         Please use RANDI instead.
         To disable this warning, type
         warning('off','comm:obsolete:randint');
but everytime I startup MATLAB I have to do "warning('off','comm:obsolete:randint');"
How can I get rid of that warning permanently?

Elnaz

Subject: How to get rid of obsolete function warning

From: John D'Errico

Date: 9 Apr, 2013 00:07:09

Message: 2 of 4

"Elnaz " <ebsadeghian@gmail.com> wrote in message <kjvlb2$6op$1@newscl01ah.mathworks.com>...
> Hi all,
> Since I'm using randint function I receive:
> Warning: This is an obsolete function and may be removed in the
> future.
> Please use RANDI instead.
> To disable this warning, type
> warning('off','comm:obsolete:randint');
> but everytime I startup MATLAB I have to do "warning('off','comm:obsolete:randint');"
> How can I get rid of that warning permanently?
>
> Elnaz

Why not just switch to randi?

It won't be long before randint does disappear, and
then you will need to do so anyway.

John

Subject: How to get rid of obsolete function warning

From: dpb

Date: 9 Apr, 2013 00:24:34

Message: 3 of 4

On 4/8/2013 6:54 PM, Elnaz wrote:
> Hi all,
> Since I'm using randint function I receive:
> Warning: This is an obsolete function and may be removed in the
> future.
> Please use RANDI instead.
> To disable this warning, type
> warning('off','comm:obsolete:randint');
> but everytime I startup MATLAB I have to do
> "warning('off','comm:obsolete:randint');"
> How can I get rid of that warning permanently?

Update your code to use RANDI instead, maybe??? It'll only get worse
when TMW actually removes it.

--

Subject: How to get rid of obsolete function warning

From: Elnaz

Date: 9 Apr, 2013 02:48:09

Message: 4 of 4

Yes; I agree. Thanks.
Elnaz

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