in case of binary logistic regressionthe target variables must be binary always and the desired outcome is represented by the factor level there should not be any multi-collinearity in the modelwhich means independent variables must be independent of each other we must include meaningful variables in our model we should choose large sample size for logistic regression the binary logistic regression model the simplest form of logistic regression is binary or binomial logistic regression in which the target or dependent variable can have only possible types either or it allows us to model relationship between multiple predictor variables and binary/binomial target variable in case of logistic regressionthe linear function is basically used as an input to another function such as in the following relationh (xgt )where < < hereg is the logistic or sigmoid function which can be given as followsg( where - to sigmoid curve can be represented with the help of following graph we can see the values of -axis lie between and and crosses the axis at the classes can be divided into positive or negative the output comes under the probability of positive class if it lies between and for our implementationwe are interpreting the output of hypothesis function as positive if it is > otherwise negative we also need to define loss function to measure how well the algorithm performs using the weights on functionsrepresented by theta as followsh (xj( (- log( ( ) log( )