subsetdata: Extracts data subsets

Description Usage Arguments Details Value Note Author(s) Examples

Description

The function diplays the individuals from a ggene object and allows to extract a subset of points by clicking the display.

Usage

1
subsetdata(X, L = NULL, col = NULL)

Arguments

X

A ggene object.

L

An optional list of ggene objects resulting from previous runs of the function (see details and examples).

col

The color to be used to display the points.

Details

This function is derived from the function clickpoly from package spatstat which allows the user to create a polygonal window by interactively clicking on the screen display. subsetdata returns the corresponding subset of individuals in the form of a new ggene object. The argument L allows superimposing previous extractions to the current graphical display to ease manual polygon definition (see example and package vignette : vignette("introduction_to_ggene")).

Value

X

A ggene object corresponding tot he extracted data subset.

subset.ppp

A ppp object (see package spatstat for details) containing the points corresponging to the extracted indivicuals. Mostly useful for graphical outputs and internal use.

original.ppp

A ppp object corresponding to the original set of individuals location. For internal use or graphical outputs.

Note

See the package vignette for examples, for that type vignette("introduction_to_ggene").

Author(s)

Jean-Pierre Rossi <ggene.package@gmail.com>

Examples

1
2
3
4
5
6
7
8
## Not run: 

data(sim02)
sub <- subsetdata(X=sim02, col="blue")
class(sub[[1]])
sub2 <- subsetdata(X=sim02, col="blue", L=list(sub))

## End(Not run)

ggene documentation built on May 2, 2019, 5:54 p.m.