% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/nr-color.R
\name{nr_dither}
\alias{nr_dither}
\title{Dither to binary image}
\usage{
nr_dither(nr, value = 0.5, algo = "fs")
}
\arguments{
\item{nr}{native raster image}

\item{value}{Threshold value. Default: 0.5  (valid range [0, 1])}

\item{algo}{Dithering algorithm. 'fs' (floyd-steinberg) or 'atkinson'. 
Default: 'fs'}
}
\value{
Invisibly return the supplied native raster image which was been
        modified in-place
}
\description{
Dither to binary image
}
\examples{
nr <- nr_copy(deer[[1]])
plot(nr)

nr_dither(nr, 0.99)
plot(nr)
}
\seealso{
Other color manipulation functions: 
\code{\link{nr_color_replace}()},
\code{\link{nr_desaturate}()},
\code{\link{nr_threshold}()}
}
\concept{color manipulation functions}
