How to fill a table using (end,:)

Hello everyone!
I have a table for example A=[2,11,33;41,25,92;11,20,14] and i want to add a new row in the end.Something like that:
A(end+1,:)=...?
My problem is that i don't know how to syntax the right part..
Thanks.

1 Comment

You know the syntax for a [3 x 3] matrix, as we see in your question. Now your need the syntax for a [1 x 3] vector.
This is a very basic question and I stronlgy suggest to read the Getting Started chapters in the documentation.

Sign in to comment.

 Accepted Answer

A=[2,11,33;41,25,92;11,20,14]
% e.g.
A(end+1,:)= rand(1,size(A,2))
or
A(end+1,:)= [3 5 6]
ets.

More Answers (0)

Categories

Find more on Creating, Deleting, and Querying Graphics Objects in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!