The expression jj = (2016:2023)
in MATLAB creates a row vector with elements ranging from 2016 to 2023 in steps of one. The resulting vector jj
contains seven elements: [2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023]
.
This syntax can also be used to create a column vector:
main.m19 chars2 lines
The apostrophe syntax creates the transpose of the row vector, resulting in a column vector with the same values.
gistlibby LogSnag