print(size(ls("-sl","-type","transform"))), although the real problem is the term object which is only very loosely defined by maya (or strictly but your not using it in the computational meaning), see form my point of view what you call an object is a packet that contains a transform and a shape, ok so what is a packet that contains a transofrm and 2 shapes then? Now if a group is a transform with transforms under it and a trasform with transform shape and shape under it is a parent linkage. then the two shape transform is umm a double object, a supergroup, or a collapsed shape?? Whatabout 2 shapes and a transofrm, or 3?