logistic.R