In Windows only one can do memory.size()
to get the total amount of memory eaten up by the (objects in the) current R
session.
It's also possible to understand the size of an individual object with print( object.size( thing ), units='auto')
which says how many megabytes/kilobytes that particular data-frame/table takes up.
But how to do the equivalent of print( object.size( ---workspace--- ))
?
Looping for (thing in ls()) print( object.size( thing ), units='auto' )
prints the wrong output, such as:
64 bytes
72 bytes
88 bytes
88 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
72 bytes
88 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
64 bytes
which is not what I meant.