Description Usage Arguments Value Examples
Wrapper function to create an Individuals object using SpatialPoints and dataframe.
The SpatialPoints object and the data.frame have to contain the same number of coordinates and rows.
1 | loadIndividuals(objectL, sp, data, mintime, maxtime)
|
objectL |
a Landscape object |
sp |
a SpatialPoint object (individuals coordinates) |
data |
a data.frame containing individuals attributes. Rows numbers as individuals ID, columns names as dob (date of birth) | life_duration | toxic_threshold |
mintime |
Start simulation time |
maxtime |
End simulation time |
an Individuals-class
object
1 2 3 4 5 6 7 8 9 |
## Not run:
# simulate individuals coordinates (SpatialPoints object):
coordinates <- spsample(getSPReceptors(land),n=2)
df <- data.frame("dob"=c(1,8),"life_duration"=c(20,20),
"toxic_threshold"=c(15,15),row.names = c(1,2))
ind <- loadIndividuals(objetL=land,sp=coordinates,data=df,mintime=1,maxtime=60)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.