Dear R users, I have a table with the following form STATION X Y 1 -70 30 1 -70 30 1 -70 30 2 -72 29 2 -72 29 2 -72 29 2 -72 29 How want to extract unique value for those columns ... I am sure it is very simple, but I can not achieve to find the correct way ! I want to obtain something like STATION X Y 1 -70 30 2 -72 29 Thanks !!! [[alternative HTML version deleted]]
Hi Arnaud, is very simple:> unique( datos)Regards 2009/3/10 <ARNAUD_MOSNIER@uqar.qc.ca>> > Dear R users, > > I have a table with the following form > > STATION X Y > 1 -70 30 > 1 -70 30 > 1 -70 30 > 2 -72 29 > 2 -72 29 > 2 -72 29 > 2 -72 29 > > How want to extract unique value for those columns ... I am sure it is very > simple, but I can not achieve to find the correct way ! > > I want to obtain something like > > STATION X Y > 1 -70 30 > 2 -72 29 > > Thanks !!! > > [[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. >[[alternative HTML version deleted]]
see ?unique
Justin BEM
BP 1917 Yaoundé
Tél (237) 99597295
(237) 22040246
________________________________
De : "ARNAUD_MOSNIER@UQAR.QC.CA" <ARNAUD_MOSNIER@UQAR.QC.CA>
À : r-help@r-project.org
Envoyé le : Mardi, 10 Mars 2009, 17h15mn 57s
Objet : [R] (no subject)
Dear R users,
I have a table with the following form
STATION X Y
1 -70 30
1 -70 30
1 -70 30
2 -72 29
2 -72 29
2 -72 29
2 -72 29
How want to extract unique value for those columns ... I am sure it is
very[[elided Yahoo spam]]
I want to obtain something like
STATION X Y
1 -70 30
2 -72 29
Thanks !!!
[[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.
[[alternative HTML version deleted]]