Creating a time vector

2 ビュー (過去 30 日間)
Kate
Kate 2013 年 7 月 8 日
コメント済み: Kate 2018 年 5 月 21 日
Silly question:
How do I create a time vector from scratch, say beginning in 1981 and ending in 2010?
Thanks
  2 件のコメント
Jan
Jan 2013 年 7 月 8 日
It depends on what a "time vector" is.
per isakson
per isakson 2013 年 7 月 8 日
編集済み: per isakson 2013 年 7 月 8 日
Is your question related to Time Series Basics in Matlab?

サインインしてコメントする。

採用された回答

Jan
Jan 2013 年 7 月 8 日
It depends on what a "time vector" is. Perhaps a datenum vector with a step size of days?
v = datenum(1981, 1, 1):datenum(2010, 11, 31);
A similar approach works for a stepsize of seconds or hours etc.
  3 件のコメント
pruth
pruth 2018 年 5 月 21 日
hi, and what if I want this time vector with 1 min interval.? how to make it possible?
Kate
Kate 2018 年 5 月 21 日
If you add another number after the 1 or 31 it would be a minute vector, then you can just extract that.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeTime Series Objects についてさらに検索

タグ

製品

Community Treasure Hunt

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

Start Hunting!

Translated by