MATLAB: Reformatting Dates date Hi, I have dates in the format 12/01/2011. Is there a way to reformat these dates by removing the forward slashes? For example, I want 12/01/2011 to become 12012011. Thanks. Best Answer strrep is faster than regexprep:a = '12/01/2011';% Or a cell string also:% a = {'12/01/2011', '12/01/2012'};b = strrep(a, '/', ''); Related SolutionsMATLAB: Datetime problem of converting string hh is uppercaseD=datetime('2019/09/05 19:02:11', 'InputFormat','yyyy/MM/dd HH:mm:ss') MATLAB: Re-formatting a matrix dout = reshape(d(:,2),numel(depth),[]).'; Related QuestionCan’t convert a cell array to a date using cellfun(@datenum or @datetime)Reformatting cell arrays of cell arraysConverting cell array to matlab datetime formatAutomatic text editor for reformatting GCODE filesHow to defining date formatDate ConversionHelp reformatting table for a Faster RCNN
Best Answer