How to concatenate 2 time series that both start from zero?

1 visualizzazione (ultimi 30 giorni)
Hi all
How to concatenate 2 time series that both start from zero? Given that both of them have the same time step? Example :
t1=[0,1,2,3]
t2=[0,1,2]
Output
T=[0,1,2,3,4,5]
  4 Commenti
Akira Agata
Akira Agata il 29 Dic 2019
Sounds like T = [t1,max(t1)+t2(2:end)].
But could you tell us what is your purpose to create this output? Because, at this time, I have no idea how to utilize this output vector T.
farzad
farzad il 29 Dic 2019
Thank you that worked great !
this is a time series that correlates another variable that changes with time, anything you can immagine, temperature, displacement , velocity. and since that variable is measured in different times , each time , the t variable starts from zero , but now I wanted to plot the whole together
there is one problem now , that since the t2(2:end) starts from the second member, then the total t with have one member less that the total members of the function variable , let's say the velocity

Accedi per commentare.

Risposte (0)

Categorie

Scopri di più su Creating and Concatenating Matrices in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by