Re: [R] how to get the data in a circle

From: Per Jensen <perjmi_at_gmail.com>
Date: Fri 26 May 2006 - 05:31:28 EST

Assuming your data frame is called dat something like dat[(dat$x-a)^2+(dat$y-b)^2<=k,]
should work I think.

On 5/25/06, zhang jian <jzhang1982@gmail.com> wrote:
>
> I want to get the data in a circle from a large square plot.
>
> If the data includes only two columns or more columns which is number
> style,
> I can do it.
> But if the data includes other columns which is not number style (e.g.
> species name), I donot know how to do it. And I donot want to delete the
> columns because it is useful to me.
> e.g. species x y
> a 12 20
> b 20 50
> c 14 25
> ... ... ...
>
> Thanks!
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help@stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide!
> http://www.R-project.org/posting-guide.html
>

        [[alternative HTML version deleted]]



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Fri May 26 05:42:05 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Fri 26 May 2006 - 06:10:22 EST.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.