Skip to main content
Added reference & links
Source Link
Scortchi
  • 31.6k
  • 9
  • 102
  • 281

You are using it wrong, there are three possible input formats for logistic regression in R

  1. As a factor: ‘success’ is interpreted as the factor not having the first level (and hence usually of having the second level).
    2. As a numerical vector with values between 0 and 1, interpreted as the proportion of successful cases (with the total number of cases given by the weights).
    3. As a two-column integer matrix: the first column gives the number of successes and the second the number of failures.

Logistic regression is an univariate model, if you have two target variables, then you need to use a different model (there isare a number of choices, including the bivariate logistic regression model mentionedgiven by Palmgren (1989), "Regression Models for Bivariate Binary Responses", UW Biostatistics Working Paper Series, 101, and implemented by binom2.or in comment belowthe VGAM package).

You are using it wrong, there are three possible input formats for logistic regression in R

  1. As a factor: ‘success’ is interpreted as the factor not having the first level (and hence usually of having the second level).
    2. As a numerical vector with values between 0 and 1, interpreted as the proportion of successful cases (with the total number of cases given by the weights).
    3. As a two-column integer matrix: the first column gives the number of successes and the second the number of failures.

Logistic regression is an univariate model, if you have two target variables, then you need to use different model (there is a number of choices, including bivariate logistic regression model mentioned in comment below).

You are using it wrong, there are three possible input formats for logistic regression in R

  1. As a factor: ‘success’ is interpreted as the factor not having the first level (and hence usually of having the second level).
    2. As a numerical vector with values between 0 and 1, interpreted as the proportion of successful cases (with the total number of cases given by the weights).
    3. As a two-column integer matrix: the first column gives the number of successes and the second the number of failures.

Logistic regression is an univariate model, if you have two target variables, then you need to use a different model (there are a number of choices, including the bivariate logistic regression model given by Palmgren (1989), "Regression Models for Bivariate Binary Responses", UW Biostatistics Working Paper Series, 101, and implemented by binom2.or in the VGAM package).

added 121 characters in body
Source Link
Tim
  • 141.2k
  • 26
  • 270
  • 512

You are using it wrong, there are three possible input formats for logistic regression in R

  1. As a factor: ‘success’ is interpreted as the factor not having the first level (and hence usually of having the second level).
    2. As a numerical vector with values between 0 and 1, interpreted as the proportion of successful cases (with the total number of cases given by the weights).
    3. As a two-column integer matrix: the first column gives the number of successes and the second the number of failures.

There's no such a thing as logisticLogistic regression withis an univariate model, if you have two binary outcometarget variables, then you need to use different model (there is a number of choices, including bivariate logistic regression model mentioned in comment below).

You are using it wrong, there are three possible input formats for logistic regression in R

  1. As a factor: ‘success’ is interpreted as the factor not having the first level (and hence usually of having the second level).
    2. As a numerical vector with values between 0 and 1, interpreted as the proportion of successful cases (with the total number of cases given by the weights).
    3. As a two-column integer matrix: the first column gives the number of successes and the second the number of failures.

There's no such a thing as logistic regression with two binary outcome variables, you need to use different model.

You are using it wrong, there are three possible input formats for logistic regression in R

  1. As a factor: ‘success’ is interpreted as the factor not having the first level (and hence usually of having the second level).
    2. As a numerical vector with values between 0 and 1, interpreted as the proportion of successful cases (with the total number of cases given by the weights).
    3. As a two-column integer matrix: the first column gives the number of successes and the second the number of failures.

Logistic regression is an univariate model, if you have two target variables, then you need to use different model (there is a number of choices, including bivariate logistic regression model mentioned in comment below).

Source Link
Tim
  • 141.2k
  • 26
  • 270
  • 512

You are using it wrong, there are three possible input formats for logistic regression in R

  1. As a factor: ‘success’ is interpreted as the factor not having the first level (and hence usually of having the second level).
    2. As a numerical vector with values between 0 and 1, interpreted as the proportion of successful cases (with the total number of cases given by the weights).
    3. As a two-column integer matrix: the first column gives the number of successes and the second the number of failures.

There's no such a thing as logistic regression with two binary outcome variables, you need to use different model.