M-file that calculate weeknumber based on a date. Date can be given as scalar or a vector. Datevalues can also be provided as textvalues, but then must a second variable describing the that format also be read in.
In addtion can a third variable be sat to true or false, and this will add year number to the output.
Given the date 01.01.2011, the function will return [52 2011].
Cite As
Gunnar Aronsen (2024). Weeknumber (https://www.mathworks.com/matlabcentral/fileexchange/31288-weeknumber), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Created with
R2010b
Compatible with any release
Platform Compatibility
Windows macOS LinuxCategories
Find more on Dates and Time in Help Center and MATLAB Answers
Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
Version | Published | Release Notes | |
---|---|---|---|
1.0.0.0 |