% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/lcmsPlot-class.R
\name{lp_purity_distribution}
\alias{lp_purity_distribution}
\title{Plot the distribution of precursor ion purity scores per sample}
\usage{
lp_purity_distribution(sample_ids = NULL, threshold = NULL, type = "violin")
}
\arguments{
\item{sample_ids}{A \code{character} vector of sample IDs to include.
\code{NULL} uses all samples.}

\item{threshold}{A \code{numeric} value in \verb{[0, 1]} drawn as a horizontal
reference line. \code{NULL} suppresses the line.}

\item{type}{A \code{character} value; one of \code{"violin"}, \code{"boxplot"},
or \code{"jitter"}. Defaults to \code{"violin"}.}
}
\value{
A layer function for use with the \code{+} operator.
}
\description{
\code{lp_purity_distribution()} generates a violin (or box/jitter) plot of
\code{inPurity} scores grouped by sample. An optional horizontal dashed line
marks a purity acceptance threshold. Requires the data object to be a
\code{purityA} result from the msPurity package.
}
