On Wed, Aug 29, 2012 at 4:23 AM, Liviu Andronic wrote:
> On Tue, Aug 28, 2012 at 9:05 PM, Duncan Murdoch
> wrote:
>> On 28/08/2012 2:16 PM, Liviu Andronic wrote:
>>> I came up with a modified version of the above:
>>> print_noattr <- function(x, keep.some=T, ...){
>>> if(keep.some) xa <- att
On Tue, Aug 28, 2012 at 9:05 PM, Duncan Murdoch
wrote:
> On 28/08/2012 2:16 PM, Liviu Andronic wrote:
>> I came up with a modified version of the above:
>> print_noattr <- function(x, keep.some=T, ...){
>> if(keep.some) xa <- attributes(x)[c('names', 'row.names', 'class')]
>> attributes(
On 28/08/2012 2:16 PM, Liviu Andronic wrote:
On Tue, Aug 28, 2012 at 7:34 PM, Duncan Murdoch
wrote:
> Assign a class to the object, and write a print method for it.
>
> For example, this doesn't quite do what you want, but it's a start:
>
> print.noattributes <- function(x, ...) {
>attribute
On Tue, Aug 28, 2012 at 1:16 PM, Liviu Andronic wrote:
> On Tue, Aug 28, 2012 at 7:34 PM, Duncan Murdoch
> wrote:
>> Assign a class to the object, and write a print method for it.
>>
>> For example, this doesn't quite do what you want, but it's a start:
>>
>> print.noattributes <- function(x, ...
On Tue, Aug 28, 2012 at 7:34 PM, Duncan Murdoch
wrote:
> Assign a class to the object, and write a print method for it.
>
> For example, this doesn't quite do what you want, but it's a start:
>
> print.noattributes <- function(x, ...) {
>attributes(x) <- NULL
>print(x)
> }
>
> class(x) <-
On 2012-08-28 10:34, Duncan Murdoch wrote:
On 28/08/2012 1:12 PM, Liviu Andronic wrote:
Dear all
Suppose the object below:
require(Hmisc)
require(plyr)
x <- dlply(iris, .(Species), describe)
How can I print the object without displaying the attributes? I
inspected ?print and ?print.default wi
On 28/08/2012 1:12 PM, Liviu Andronic wrote:
Dear all
Suppose the object below:
> require(Hmisc)
> require(plyr)
> x <- dlply(iris, .(Species), describe)
How can I print the object without displaying the attributes? I
inspected ?print and ?print.default with no luck.
Assign a class to the obje
On 18/01/2009, at 7:55 PM, Pedro Mardones wrote:
Dear all;
I have a function written in R that returns as a list of values as
output that has associated some user defined attributes to it. How can
hide these attributes when printing the output on screen? I'm using
R-2.8.1 on WinXPit's like
Is this what you want:
> y <- scale(x)
> str(x)
int [1:10] 1 2 3 4 5 6 7 8 9 10
> str(y)
num [1:10, 1] -1.486 -1.156 -0.826 -0.495 -0.165 ...
- attr(*, "scaled:center")= num 5.5
- attr(*, "scaled:scale")= num 3.03
> y
[,1]
[1,] -1.4863011
[2,] -1.1560120
[3,] -0.8257228
[4,] -0
9 matches
Mail list logo