A common situation in physics is to have a signal which is mixed in with
some background. In this note, we describe a procedure for determining
on an event-by-event basis the chance ($Q$-factor) that a given event comes from the
signal distribution. This chance can then be used as an event weight in subsequent analysis procedures, allowing one to more directly access the true spectrum of the signal. In addition to the Q-factor, we describe a method to determine the error on the Q-factor, sigma_Q and how these errors are combined to determine the errors on observables.