[R] Odp: Need to clean a table, and compute mean and SD

Petr PIKAL petr.pikal at precheza.cz
Mon May 4 11:39:57 CEST 2009


Hi

r-help-bounces at r-project.org napsal dne 04.05.2009 09:53:19:

> 
> Hi
> 
> For a school project I have a file with 120 columns and  ~2000 lines. 
This
> file contains timestamps of spike detected in 60 channels, and the time
> elapsed between the last spike.
> 
> I need to clean too high values. About 98% of values are between 0 and 
2000
> and 2% are between 2000 and 20'000. I want to get rid of theses values.
> 
> Please could you help me?

Decide your threshold value. Let say it is 2000. Then it depends how do 
you want to get rid of the data.

e.g.

mat[mat>2000]<-NA

shall put NA values instead all items which were bigger than 2000.

Regards
Petr



> 
> Regards 
> 
> Thom
> -- 
> View this message in context: 
http://www.nabble.com/Need-to-clean-a-table%2C-
> and-compute-mean-and-SD-tp23364460p23364460.html
> Sent from the R help mailing list archive at Nabble.com.
> 
> ______________________________________________
> R-help at 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.




More information about the R-help mailing list