How can I merge a numeric matrix (1 column) to an existing numeric matrix?

1 view (last 30 days)
I have created a column numeric matrix like that
A={1
2
3
....}
and I want to merge it to an existing matrix (B) at a specific cell (sc)
B= {
time data
time data
time (sc) 1
time
... }.
so that i would look like this
B= {
time data
time data
time 1
time 2
... 3 }.
If anyone can help me I would really appreciate it. I'm new here and I do not know that mny functions

Accepted Answer

dpb
dpb on 4 Jul 2019
Presuming the B vector already exists to match the right size, simply knowing the row number is sufficient...
B(sc:end,2)=A;

More Answers (0)

Categories

Find more on Multidimensional Arrays in Help Center and File Exchange

Products


Release

R2018a

Community Treasure Hunt

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

Start Hunting!