How can I create a vector where the elements are 24 hours a day?
Thanks

Answers (1)

hours(0 : 23)
ans = 1×24 duration array
0 hr 1 hr 2 hr 3 hr 4 hr 5 hr 6 hr 7 hr 8 hr 9 hr 10 hr 11 hr 12 hr 13 hr 14 hr 15 hr 16 hr 17 hr 18 hr 19 hr 20 hr 21 hr 22 hr 23 hr

Categories

Find more on Aerospace Blockset 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!