In case-control studies one may employ logistic regression to model the relationship between binary responses and continuous predictor variables that have been categorized by the empirical quartiles of the controls. Sometimes, however, systematic trends over time (or drifts) contaminate the laboratory measurements of predictor variables. In this paper we consider the use of locally weighted robust regression (lowess) to estimate and remove these systematic trends when the trends for the cases and controls have a common shape. One can then use the lowess adjusted data in the desired logistic regression model. We illustrate these methods with a case-control study that was designed to assess the risk of oesophageal cancer as a function of the quartile categories of sphinganine levels in the blood serum. Upon examination of the data, it was discovered that the sphinganine laboratory measurements were contaminated by a systematic trend, the magnitude of which depended only on the day of analysis. This trend needed to be removed before performing further analyses of the data. In addition, we present simulations to examine the use of lowess methods to estimate and remove various shapes of trends from contaminated predictor data before constructing logistic regression models with quartile categories. We found that using the trend-contaminated data tends to give attenuated parameter estimates and hence lower significance and power levels than using the uncontaminated data. Conversely, using appropriate lowess methods to adjust the data tends to give nearly unbiased parameter estimates, near nominal significance levels, and improved power.