This line needs to be replaced. If `demean` isn't a `Bool`, this will raise a type error: `ERROR: type: non-boolean (Float64) used in boolean context`.