Loop with two varying conditions
显示 更早的评论
Hello
I would like to have some help with the following (probably simple but has me stumped) problem.
I have a matrix [35040 x 2] consisting of a datenumber series in one column and corresponding values. I also have a vector [12 x 1] values.
I am trying to add each value from the vector to all values in each corresponding month in the matrix. Like this:
(lets call this a month)
735235.010416667 4.36000000000000
735235.020833333 4.44000000000000
735235.031250000 4.43500000000000
735235.041666667 4.41000000000000
735235.052083333 4.37000000000000
735235.062500000 4.35000000000000
735235.072916667 4.35000000000000
Add value vector(1,1) to the above. Then repeat this by adding value vector(2,1) to the values of month 2 from matrix.
Any help really appreciated. Thanks !
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 MATLAB 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!