Hi all,

I have data size of :

> dim(sample)
[1] 35943    17

The first column is "stdate"  - is date  ( 01/11/2009 00:00:00,02/11/2009
00:00:00,02/11/2009 00:00:00 etc... )
Login is 13th column - is numbers (12,0,1 erc...)

The below operation return the following error.

> sample1 <- read.csv(file="sample1.csv",sep=",",header=TRUE)
> avglog <- with(sample1, tapply(Login, stdate, mean))

Warning messages:
1: In mean.default(X[[1L]], ...) :
  argument is not numeric or logical: returning NA
2: In mean.default(X[[2L]], ...) :
  argument is not numeric or logical: returning NA
3: In mean.default(X[[3L]], ...) :
  argument is not numeric or logical: returning NA
4: In mean.default(X[[4L]], ...) :
  argument is not numeric or logical: returning NA
5: In mean.default(X[[5L]], ...) :
  argument is not numeric or logical: returning NA
6: In mean.default(X[[6L]], ...) :
  argument is not numeric or logical: returning NA
7: In mean.default(X[[7L]], ...) :
  argument is not numeric or logical: returning NA


> avglog
01/11/09 00:00 02/11/09 00:00 03/11/09 00:00 04/11/09 00:00 05/11/09 00:00
            NA             NA             NA             NA             NA

How to fix this issue?

Thanks & Rg
Mohan L

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to