% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/dotprops.R
\name{subset.dotprops}
\alias{subset.dotprops}
\title{Subset points in dotprops object that match given conditions}
\usage{
\method{subset}{dotprops}(x, subset, ...)
}
\arguments{
  \item{x}{A dotprops object}

  \item{subset}{A subset of points defined by indices or a
  function (see Details)}

  \item{...}{Additional parameters (currently ignored)}
}
\value{
subsetted dotprops object
}
\description{
Subset points in dotprops object that match given
conditions
}
\details{
\code{subset} defines either logical or numeric indices, in
which case these are simply applied to the matrices that
define the points, vect etc OR a function (which is called
with the 3d points array and returns T/F vector).
}
\examples{
\dontrun{
s3d=select3d()
dp1=subset(dp,s3d(points))
# special case of previous version
dp2=subset(dp,s3d)
# keep the points that were removed from dp2
dp2.not=subset(dp,Negate(s3d))
stopifnot(all.equal(dp1,dp2))
dp2=subset(dp,alpha>0.5 & s3d(pointd))
dp3=subset(dp,1:10)

## subset each dotprops object in a whole neuronlist
plot3d(kcs20)
s3d=select3d()
kcs20.partial = nlapply(kcs20, subset, s3d)
clear3d()
plot3d(kcs20.partial, col='red')
plot3d(kcs20, col='grey')
}
}
\seealso{
\code{prune.dotprops}
}

