What is metrics.roc_curve and metrics.auc measuring when I'm comparing binary data with probability estimates?Fastest way to compare ROC curvesLogistic regression: maximizing true positives - false positivesHow to compute the AUROC for a single categorical variableWhat is the effect of training a model on an imbalanced dataset & using it on a balanced dataset?Is sensitivity, specificity and g-mean considered as “point-wise” metricsHow to improve F1 score with skewed classes?Using “accuracy” as a measure of performance for logistic regressionHow to determine if the predicted probabilities from sklearn logistic regresssion are accurate?Bootstrapping for imbalanced and small sample sized dataDoes a low Area Under Curve (AUC) for ROC imply worthless classifier?

Can't think of a good word or term to describe not feeling or thinking

Vehemently against code formatting

What is metrics.roc_curve and metrics.auc measuring when I'm comparing binary data with probability estimates?

What does "bella ciao" mean literally?

If you attack a Tarrasque while swallowed, what AC do you need to beat to hit it?

What quantum phenomena violate the superposition principle in electromagnetism?

1950s or earlier book with electrical currents living on Pluto

How can I prevent Bash expansion from passing files starting with "-" as argument?

Way of refund if scammed?

Hotel booking: Why is Agoda much cheaper than booking.com?

Why does an injection from a set to a countable set imply that set is countable?

Working hours and productivity expectations for game artists and programmers

Why was Harry at the Weasley's at the beginning of Goblet of Fire but at the Dursleys' after?

Separate the element after every 2nd ',' and push into next row in bash

Presenting 2 results for one variable using a left brace

How to safely discharge oneself

Best practice for printing and evaluating formulas with the minimal coding

How to tease a romance without a cat and mouse chase?

Salesforce bug enabled "Modify All"

Why is こと used in 「私に何かできること」?

Was Tyrion always a poor strategist?

Warped chessboard

Bash - Execute two commands and get exit status 1 if first fails

Is being an extrovert a necessary condition to be a manager?



What is metrics.roc_curve and metrics.auc measuring when I'm comparing binary data with probability estimates?


Fastest way to compare ROC curvesLogistic regression: maximizing true positives - false positivesHow to compute the AUROC for a single categorical variableWhat is the effect of training a model on an imbalanced dataset & using it on a balanced dataset?Is sensitivity, specificity and g-mean considered as “point-wise” metricsHow to improve F1 score with skewed classes?Using “accuracy” as a measure of performance for logistic regressionHow to determine if the predicted probabilities from sklearn logistic regresssion are accurate?Bootstrapping for imbalanced and small sample sized dataDoes a low Area Under Curve (AUC) for ROC imply worthless classifier?






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








1












$begingroup$


I was working on a challenge, and I was excited because the metric.auc for my predicted values compared to my test values was very high. This was for a binary selection process.



However, when I looked at it, my predicted values outputted by logistic regression were actually probabilities, not binary values.



So I rounded them, as the challenge requires binary predictions. When I rounded them, the auc score dropped drastically.



My understanding of the auc score and roc curve is that it compares false positives/negatives etc., and I don't even know how it came up with an actual value for these probabilistic predictions.



What was it computing before, and why was it so high?










share|cite|improve this question







New contributor



Brian Rushton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






$endgroup$


















    1












    $begingroup$


    I was working on a challenge, and I was excited because the metric.auc for my predicted values compared to my test values was very high. This was for a binary selection process.



    However, when I looked at it, my predicted values outputted by logistic regression were actually probabilities, not binary values.



    So I rounded them, as the challenge requires binary predictions. When I rounded them, the auc score dropped drastically.



    My understanding of the auc score and roc curve is that it compares false positives/negatives etc., and I don't even know how it came up with an actual value for these probabilistic predictions.



    What was it computing before, and why was it so high?










    share|cite|improve this question







    New contributor



    Brian Rushton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.






    $endgroup$














      1












      1








      1





      $begingroup$


      I was working on a challenge, and I was excited because the metric.auc for my predicted values compared to my test values was very high. This was for a binary selection process.



      However, when I looked at it, my predicted values outputted by logistic regression were actually probabilities, not binary values.



      So I rounded them, as the challenge requires binary predictions. When I rounded them, the auc score dropped drastically.



      My understanding of the auc score and roc curve is that it compares false positives/negatives etc., and I don't even know how it came up with an actual value for these probabilistic predictions.



      What was it computing before, and why was it so high?










      share|cite|improve this question







      New contributor



      Brian Rushton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






      $endgroup$




      I was working on a challenge, and I was excited because the metric.auc for my predicted values compared to my test values was very high. This was for a binary selection process.



      However, when I looked at it, my predicted values outputted by logistic regression were actually probabilities, not binary values.



      So I rounded them, as the challenge requires binary predictions. When I rounded them, the auc score dropped drastically.



      My understanding of the auc score and roc curve is that it compares false positives/negatives etc., and I don't even know how it came up with an actual value for these probabilistic predictions.



      What was it computing before, and why was it so high?







      logistic python auc






      share|cite|improve this question







      New contributor



      Brian Rushton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.










      share|cite|improve this question







      New contributor



      Brian Rushton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.








      share|cite|improve this question




      share|cite|improve this question






      New contributor



      Brian Rushton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.








      asked 2 hours ago









      Brian RushtonBrian Rushton

      82




      82




      New contributor



      Brian Rushton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.




      New contributor




      Brian Rushton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






















          1 Answer
          1






          active

          oldest

          votes


















          2












          $begingroup$

          When you round up/down the predicted probabilities, you are essentially using 0.5 as a threshold for your classification. ROC curves do this not for one but for every possible threshold. The false positive rates and true positive rates are then plotted as roc curve (with the integral being the auc).



          If the challenge requires you to provide binary predictions, they are unlikely to use AUC as performance measure.






          share|cite|improve this answer











          $endgroup$








          • 1




            $begingroup$
            Congrats on hitting 1000!
            $endgroup$
            – Matthew Drury
            1 hour ago






          • 1




            $begingroup$
            The $c$-index (concordance probability; area under ROC curve) is a decent pure measure of predictive discrimination when computed on the continuous probabilities and the binary outcomes. But proper accuracy scoring rules in this case are the Brier score and the pseudo $R^2$, which are more sensitive because they give more credit to extreme probabilities that are "right".
            $endgroup$
            – Frank Harrell
            1 hour ago











          Your Answer








          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "65"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );






          Brian Rushton is a new contributor. Be nice, and check out our Code of Conduct.









          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstats.stackexchange.com%2fquestions%2f408976%2fwhat-is-metrics-roc-curve-and-metrics-auc-measuring-when-im-comparing-binary-da%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          2












          $begingroup$

          When you round up/down the predicted probabilities, you are essentially using 0.5 as a threshold for your classification. ROC curves do this not for one but for every possible threshold. The false positive rates and true positive rates are then plotted as roc curve (with the integral being the auc).



          If the challenge requires you to provide binary predictions, they are unlikely to use AUC as performance measure.






          share|cite|improve this answer











          $endgroup$








          • 1




            $begingroup$
            Congrats on hitting 1000!
            $endgroup$
            – Matthew Drury
            1 hour ago






          • 1




            $begingroup$
            The $c$-index (concordance probability; area under ROC curve) is a decent pure measure of predictive discrimination when computed on the continuous probabilities and the binary outcomes. But proper accuracy scoring rules in this case are the Brier score and the pseudo $R^2$, which are more sensitive because they give more credit to extreme probabilities that are "right".
            $endgroup$
            – Frank Harrell
            1 hour ago















          2












          $begingroup$

          When you round up/down the predicted probabilities, you are essentially using 0.5 as a threshold for your classification. ROC curves do this not for one but for every possible threshold. The false positive rates and true positive rates are then plotted as roc curve (with the integral being the auc).



          If the challenge requires you to provide binary predictions, they are unlikely to use AUC as performance measure.






          share|cite|improve this answer











          $endgroup$








          • 1




            $begingroup$
            Congrats on hitting 1000!
            $endgroup$
            – Matthew Drury
            1 hour ago






          • 1




            $begingroup$
            The $c$-index (concordance probability; area under ROC curve) is a decent pure measure of predictive discrimination when computed on the continuous probabilities and the binary outcomes. But proper accuracy scoring rules in this case are the Brier score and the pseudo $R^2$, which are more sensitive because they give more credit to extreme probabilities that are "right".
            $endgroup$
            – Frank Harrell
            1 hour ago













          2












          2








          2





          $begingroup$

          When you round up/down the predicted probabilities, you are essentially using 0.5 as a threshold for your classification. ROC curves do this not for one but for every possible threshold. The false positive rates and true positive rates are then plotted as roc curve (with the integral being the auc).



          If the challenge requires you to provide binary predictions, they are unlikely to use AUC as performance measure.






          share|cite|improve this answer











          $endgroup$



          When you round up/down the predicted probabilities, you are essentially using 0.5 as a threshold for your classification. ROC curves do this not for one but for every possible threshold. The false positive rates and true positive rates are then plotted as roc curve (with the integral being the auc).



          If the challenge requires you to provide binary predictions, they are unlikely to use AUC as performance measure.







          share|cite|improve this answer














          share|cite|improve this answer



          share|cite|improve this answer








          edited 1 hour ago

























          answered 1 hour ago









          lnathanlnathan

          1,0281523




          1,0281523







          • 1




            $begingroup$
            Congrats on hitting 1000!
            $endgroup$
            – Matthew Drury
            1 hour ago






          • 1




            $begingroup$
            The $c$-index (concordance probability; area under ROC curve) is a decent pure measure of predictive discrimination when computed on the continuous probabilities and the binary outcomes. But proper accuracy scoring rules in this case are the Brier score and the pseudo $R^2$, which are more sensitive because they give more credit to extreme probabilities that are "right".
            $endgroup$
            – Frank Harrell
            1 hour ago












          • 1




            $begingroup$
            Congrats on hitting 1000!
            $endgroup$
            – Matthew Drury
            1 hour ago






          • 1




            $begingroup$
            The $c$-index (concordance probability; area under ROC curve) is a decent pure measure of predictive discrimination when computed on the continuous probabilities and the binary outcomes. But proper accuracy scoring rules in this case are the Brier score and the pseudo $R^2$, which are more sensitive because they give more credit to extreme probabilities that are "right".
            $endgroup$
            – Frank Harrell
            1 hour ago







          1




          1




          $begingroup$
          Congrats on hitting 1000!
          $endgroup$
          – Matthew Drury
          1 hour ago




          $begingroup$
          Congrats on hitting 1000!
          $endgroup$
          – Matthew Drury
          1 hour ago




          1




          1




          $begingroup$
          The $c$-index (concordance probability; area under ROC curve) is a decent pure measure of predictive discrimination when computed on the continuous probabilities and the binary outcomes. But proper accuracy scoring rules in this case are the Brier score and the pseudo $R^2$, which are more sensitive because they give more credit to extreme probabilities that are "right".
          $endgroup$
          – Frank Harrell
          1 hour ago




          $begingroup$
          The $c$-index (concordance probability; area under ROC curve) is a decent pure measure of predictive discrimination when computed on the continuous probabilities and the binary outcomes. But proper accuracy scoring rules in this case are the Brier score and the pseudo $R^2$, which are more sensitive because they give more credit to extreme probabilities that are "right".
          $endgroup$
          – Frank Harrell
          1 hour ago










          Brian Rushton is a new contributor. Be nice, and check out our Code of Conduct.









          draft saved

          draft discarded


















          Brian Rushton is a new contributor. Be nice, and check out our Code of Conduct.












          Brian Rushton is a new contributor. Be nice, and check out our Code of Conduct.











          Brian Rushton is a new contributor. Be nice, and check out our Code of Conduct.














          Thanks for contributing an answer to Cross Validated!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          Use MathJax to format equations. MathJax reference.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstats.stackexchange.com%2fquestions%2f408976%2fwhat-is-metrics-roc-curve-and-metrics-auc-measuring-when-im-comparing-binary-da%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Canceling a color specificationRandomly assigning color to Graphics3D objects?Default color for Filling in Mathematica 9Coloring specific elements of sets with a prime modified order in an array plotHow to pick a color differing significantly from the colors already in a given color list?Detection of the text colorColor numbers based on their valueCan color schemes for use with ColorData include opacity specification?My dynamic color schemes

          Invision Community Contents History See also References External links Navigation menuProprietaryinvisioncommunity.comIPS Community ForumsIPS Community Forumsthis blog entry"License Changes, IP.Board 3.4, and the Future""Interview -- Matt Mecham of Ibforums""CEO Invision Power Board, Matt Mecham Is a Liar, Thief!"IPB License Explanation 1.3, 1.3.1, 2.0, and 2.1ArchivedSecurity Fixes, Updates And Enhancements For IPB 1.3.1Archived"New Demo Accounts - Invision Power Services"the original"New Default Skin"the original"Invision Power Board 3.0.0 and Applications Released"the original"Archived copy"the original"Perpetual licenses being done away with""Release Notes - Invision Power Services""Introducing: IPS Community Suite 4!"Invision Community Release Notes

          François Viète Contents Biography Work and thought Bibliography See also Notes Further reading External links Navigation menup. 21Google Bookspp. 75–77Google BooksDe thou (from University of Saint Andrews)ArchivedGoogle BooksGoogle BooksGoogle BooksGoogle booksGoogle Bookscc-parthenay.frL'histoire universelle (fr)Universal History (en)ArchivedAdsabs.harvard.eduPagesperso-orange.frArchive.orgChikara Sasaki. Descartes' mathematical thought p.259Google BooksGoogle BooksGoogle Bookspp. 152 and onwardGoogle BooksGoogle BooksScribd.comGoogle Books1257-7979Google BooksGoogle BooksGoogle BooksGoogle BooksGoogle BooksGoogle BooksGallica.bnf.frGoogle BooksGoogle Books"François Viète"Francois Viète: Father of Modern Algebraic NotationThe Lawyer and the GamblerAbout TarporleySite de Jean-Paul GuichardL'algèbre nouvelle"About the Harmonicon"cb120511976(data)1188044800000 0001 0913 5903n82164680ola2013766880073431702w6vt1sb70287374827140948071409480