Skip to content

size issuing nothing on vector of datetime

Bug Description

call to the size() function on vector of datetimes is issuing nothing while the default display of the vector of datetimes is actually issuing the right information , number of rows, number of columns if matrix dimensions.

Steps to reproduce

scenmanip = [5x2 string]

  "Scenmat4"  "2024-09-06 15:14:51"
  "Scenmat3"  "2024-08-19 11:59:08"
  "Scenmat2"  "2024-08-09 15:53:10"
  "Scenmat1"  "2024-08-07 08:10:33"
  "Scenmat0"  "2024-08-02 08:10:33"

--> tpscenmanip= datetime(scenmanip(:,2))

 tpscenmanip = [5x1 datetime]

   2024-09-06 15:14:51
   2024-08-19 11:59:08
   2024-08-09 15:53:10
   2024-08-07 08:10:33
   2024-08-02 08:10:33

--> size(tpscenmanip)

--> mtps= [tpscenmanip tpscenmanip]

 mtps = [5x2 datetime]

   2024-09-06 15:14:51   2024-09-06 15:14:51
   2024-08-19 11:59:08   2024-08-19 11:59:08
   2024-08-09 15:53:10   2024-08-09 15:53:10
   2024-08-07 08:10:33   2024-08-07 08:10:33
   2024-08-02 08:10:33   2024-08-02 08:10:33

--> size(mtps)

--> 

What is the expected correct behavior?

size should return what is actually displayed in the first line of default display for datetime object.