Assumes that the data.frame
is the output of .SPE2df()
. Column order is important!
Usage
.df2ppp(df, xName, yName, marks = NULL)
Arguments
- df
data.frame; with x, y coordinates, image, and categorical mark information.
- xName
character; column name of x coordinate
- yName
character; column name of y coordinate
- marks
character; column name of the mark variable
Value
ppp; object of type ppp
Examples
data(sostaSPE)
df <- .SPE2df(sostaSPE, marks = "cellType", imageCol = "imageName")
ppp <- .df2ppp(df, xName = "x", yName = "y", marks = "cellType")