"Running Logistic Regression (Weka) for the Yes Class"

earmijoearmijo MemberPosts:270Unicorn
edited June 2019 inHelp
When I run a logistic regression (weka) sometime I get the "wrong" equation. Instead of running the regression for the positive class ("yes"), RM or Weka run it for the negative class. Is there a way of forcing RM or Weka to use the "yes" class. See example below.

I know that it doesn't make any difference for predictions. I know that the fix is very easy ("to get the coefficients for the "yes" class, just reverse the sign") but... this had been driving me crazy since I started using RM (a few years ago).

Thanks in advance for any help.

image





<宏/ >




https://s3.amazonaws.com/mirlitus/subscription.csv"/>



















Tagged:

Answers

  • MartinLiebigMartinLiebig Administrator, Moderator, Employee, RapidMiner Certified Analyst, RapidMiner Certified Expert, University ProfessorPosts:3,388RM Data Scientist
    Have you tried the Remap Binominal operator?
    - Head of Data Science Services at RapidMiner -
    Dortmund, Germany
  • earmijoearmijo MemberPosts:270Unicorn
    Thank you Martin. I have tried "Remap Binomial" but it doesn't make any difference. Perhaps it doesn't work with Weka operators.

  • MartinLiebigMartinLiebig Administrator, Moderator, Employee, RapidMiner Certified Analyst, RapidMiner Certified Expert, University ProfessorPosts:3,388RM Data Scientist
    does it work with RM Logistic regression but not with W-LogisticRegression? this would sure indicate a problem here..

    ~Martin
    - Head of Data Science Services at RapidMiner -
    Dortmund, Germany
  • lanemlanem Member, University ProfessorPosts:29Maven

    Hi

    I have the same problem where weka logistic regression operator calculates the coefficients and odds ratios for the false value but binominal remap operator can reverse this

    My other question is why does the Logistic Regression operator implemented by RapidMiner provide the odds ratios - I know you can calculate these by computing the exponential of the coefficients - but that is a manual fix would be good if the operator could provide this an output

    Regards Michael

Sign InorRegisterto comment.