Re: [S] Command for displaying structure and contents of data frames

Christian Keller (
Mon, 27 Apr 1998 08:01:43 +0200

Paul Schwarz <> wrote:
>> I've been searching for a command that will display the structure
>> and contents of a data frame similar to the information displayed
>> by the object browser in S-PLUS 4.x. For example, with the object
>> browser, if you click on a data frame in the left pane, the names
>> of the variables and whether they're doubles, factors, etc. are
>> displayed in the right pane. Is there a command-line equivalent to
>> display this kind of information? I thought that objects.summary()
>> might do it, but it doesn't seem to display the contents of a
>> particular data frame.

I would recommend you to use the function 'str' which is available
from Statlib (
str: Compactly print STRucture of any S object. S function 'str',
help, utilities and examples.
Martin Maechler ( [11/Mar/94]
[29/Nov/94][24/Mar/97] (35k)

It does (nearly) everything what you want. I'm sure you will love it.
-- Christian
Christian Keller Tel: +41 61 686 98 81
AICOS Technologies AG Fax: +41 61 686 98 88
Efringerstrasse 32 email:
CH-4057 Basel, Switzerland Web:
This message was distributed by To unsubscribe
send e-mail to with the BODY of the
message: unsubscribe s-news