The function getData returns the data stored in the @data slot of a
gData object.
Arguments
- x
a valid
gDataobject.- ...
additional arguments passed to other methods (currently unused).
Value
The data stored in the @data slot of the input object, typically a
data.frame where each row corresponds to a sampled location.
See also
getCoords to retrieve coordinates. getNodes to retrieve
matched node identifiers. getNodesAttr to retrieve node attributes
from the underlying gGraph.
Other accessor_methods:
getColors(),
getCoords(),
getCosts(),
getEdges(),
getGraph(),
getNodes(),
getNodesAttr(),
setColors(),
setGraph()
Examples
## get the data stored in the hgdp dataset
head(getData(hgdp))
#> Population Region Label n Latitude Longitude Genetic.Div
#> 1 Orcadian EUROPE 1 15 59 -3 0.7258820
#> 2 Adygei EUROPE 2 17 44 39 0.7297802
#> 3 Russian EUROPE 3 25 61 40 0.7319749
#> 4 Basque EUROPE 4 24 43 0 0.7191268
#> 5 French EUROPE 5 28 46 2 0.7312109
#> 6 Italian EUROPE 6 13 46 10 0.7280693
