added additional code for testing bagged and averaged sgd for logistic regression