how-to-calculate-the-inverse-of-the-normal-cumulative-distribution-function-in-p.1 (190189B)
1 <!DOCTYPE html> 2 3 4 <html itemscope itemtype="https://schema.org/QAPage" class="html__responsive " lang="en"> 5 6 <head> 7 8 <title>scipy - How to calculate the inverse of the normal cumulative distribution function in python? - Stack Overflow</title> 9 <link rel="shortcut icon" href="https://cdn.sstatic.net/Sites/stackoverflow/Img/favicon.ico?v=ec617d715196"> 10 <link rel="apple-touch-icon" href="https://cdn.sstatic.net/Sites/stackoverflow/Img/apple-touch-icon.png?v=c78bd457575a"> 11 <link rel="image_src" href="https://cdn.sstatic.net/Sites/stackoverflow/Img/apple-touch-icon.png?v=c78bd457575a"> 12 <link rel="search" type="application/opensearchdescription+xml" title="Stack Overflow" href="/opensearch.xml"> 13 <link rel="canonical" href="https://stackoverflow.com/questions/20626994/how-to-calculate-the-inverse-of-the-normal-cumulative-distribution-function-in-p" /> 14 <meta name="viewport" content="width=device-width, height=device-height, initial-scale=1.0, minimum-scale=1.0"> 15 <meta property="og:type" content= "website" /> 16 <meta property="og:url" content="https://stackoverflow.com/questions/20626994/how-to-calculate-the-inverse-of-the-normal-cumulative-distribution-function-in-p"/> 17 <meta property="og:site_name" content="Stack Overflow" /> 18 <meta property="og:image" itemprop="image primaryImageOfPage" content="https://cdn.sstatic.net/Sites/stackoverflow/Img/apple-touch-icon@2.png?v=73d79a89bded" /> 19 <meta name="twitter:card" content="summary"/> 20 <meta name="twitter:domain" content="stackoverflow.com"/> 21 <meta name="twitter:title" property="og:title" itemprop="name" content="How to calculate the inverse of the normal cumulative distribution function in python?" /> 22 <meta name="twitter:description" property="og:description" itemprop="description" content="How do I calculate the inverse of the cumulative distribution function (CDF) of the normal distribution in Python?

Which library should I use? Possibly scipy?" /> 23 <script id="webpack-public-path" type="text/uri-list">https://cdn.sstatic.net/</script> 24 <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script> 25 <script defer src="https://cdn.sstatic.net/Js/third-party/npm/@stackoverflow/stacks/dist/js/stacks.min.js?v=d5f780ae3281"></script> 26 <script src="https://cdn.sstatic.net/Js/stub.en.js?v=fa8bcab580cd"></script> 27 28 <link rel="stylesheet" type="text/css" href="https://cdn.sstatic.net/Shared/stacks.css?v=5d83236da4e2"> 29 <link rel="stylesheet" type="text/css" href="https://cdn.sstatic.net/Sites/stackoverflow/primary.css?v=89d00f6d5eec"> 30 31 32 33 <link rel="alternate" type="application/atom+xml" title="Feed for question 'How to calculate the inverse of the normal cumulative distribution function in python?'" href="/feeds/question/20626994"> 34 <script> 35 StackExchange.ready(function () { 36 37 StackExchange.using("snippets", function () { 38 StackExchange.snippets.initSnippetRenderer(); 39 }); 40 41 StackExchange.using("postValidation", function () { 42 StackExchange.postValidation.initOnBlurAndSubmit($('#post-form'), 2, 'answer'); 43 }); 44 45 46 StackExchange.question.init({showAnswerHelp:true,showTrendingSortLaunchPopover:false,showTrendingSortPostLaunchPopover:false,totalCommentCount:3,shownCommentCount:3,enableTables:true,questionId:20626994}); 47 48 styleCode(); 49 50 StackExchange.realtime.subscribeToQuestion('1', '20626994'); 51 StackExchange.using("gps", function () { StackExchange.gps.trackOutboundClicks('#content', '.js-post-body'); }); 52 53 54 }); 55 </script> 56 57 58 59 60 <link rel="stylesheet" type="text/css" href="https://cdn.sstatic.net/Shared/Channels/channels.css?v=64256d36becc"> 61 62 63 64 65 66 <script type="application/json" data-role="module-args" data-module-name="Shared/options.mod">{"options":{"locale":"en","serverTime":1701628369,"routeName":"Questions/Show","stackAuthUrl":"https://stackauth.com","networkMetaHostname":"meta.stackexchange.com","site":{"name":"Stack Overflow","description":"Q\u0026A for professional and enthusiast programmers","isNoticesTabEnabled":true,"enableNewTagCreationWarning":true,"insertSpaceAfterNameTabCompletion":false,"id":1,"cookieDomain":".stackoverflow.com","childUrl":"https://meta.stackoverflow.com","negativeVoteScoreFloor":null,"enableSocialMediaInSharePopup":true,"protocol":"https"},"user":{"fkey":"d8a1f9f0d8241e1b245c6f93920897c7b1457a3e09f1f846dafb3a27efbe14a3","tid":"3de1ec46-61f8-4c2b-8c1d-22354c9bb232","rep":0,"isAnonymous":true,"isAnonymousNetworkWide":true,"ab":{"job_search_status":{"v":"ai_policy_banner_v1","g":1}}},"events":{"postType":{"question":1},"postEditionSection":{"title":1,"body":2,"tags":3}}}}</script> 67 <script type="application/json" data-role="module-args" data-module-name="Shared/settings.mod">{"settings":{"userMessaging":{"showNewFeatureNotice":true},"tags":{},"subscriptions":{"defaultBasicMaxTrueUpSeats":250,"defaultFreemiumMaxTrueUpSeats":50,"defaultMaxTrueUpSeats":1000},"snippets":{"renderDomain":"stacksnippets.net","snippetsEnabled":true},"site":{"allowImageUploads":true,"enableImgurHttps":true,"enableUserHovercards":true,"forceHttpsImages":true,"stacksEditorPreviewEnabled":true,"styleCode":true},"search":{},"questions":{"enableQuestionTitleLengthLiveWarning":true,"enableSavesFeature":true,"maxTitleSize":150,"questionTitleLengthStartLiveWarningChars":50},"intercom":{"appId":"inf0secd","enableJavascriptImplementationFor":true,"hostBaseUrl":"https://stacksnippets.net"},"paths":{"jQueryUICSSPath":"https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.0/themes/smoothness/jquery-ui.css","jQueryUIJSPath":"https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.0/jquery-ui.min.js"},"mentions":{"maxNumUsersInDropdown":50},"markdown":{"enableTables":true},"legal":{"oneTrustConfigId":"c3d9f1e3-55f3-4eba-b268-46cee4c6789c"},"flags":{"allowRetractingCommentFlags":true,"allowRetractingFlags":true},"elections":{"opaVoteResultsBaseUrl":"https://www.opavote.com/results/"},"comments":{},"accounts":{"currentPasswordRequiredForChangingStackIdPassword":true}}}</script> 68 <script>StackExchange.init();</script> 69 70 <script> 71 StackExchange.using.setCacheBreakers({"Js/adops.en.js":"6da43f5e0a84","Js/ask.en.js":"","Js/begin-edit-event.en.js":"20edbaccceae","Js/copy-transpiled.en.js":"d31dc7eba3bc","Js/events.en.js":"","Js/explore-qlist.en.js":"2b1f34938b8b","Js/full-anon.en.js":"192ecaea0c9d","Js/full.en.js":"efb11489a333","Js/highlightjs-loader.en.js":"510e2f94c2bf","Js/inline-tag-editing.en.js":"3e8cc64ee9d6","Js/keyboard-shortcuts.en.js":"107c2ac31497","Js/markdown-it-loader.en.js":"5818ef89ff9d","Js/mentions-transpiled.en.js":"36b8cabd2c12","Js/moderator.en.js":"bd04c908e875","Js/postCollections-transpiled.en.js":"ea1228154a76","Js/post-validation.en.js":"8fd6c83cea6c","Js/question-editor.en.js":"","Js/review-v2-transpiled.en.js":"7b6b513b5808","Js/revisions.en.js":"47b4d5ac24c9","Js/stacks-editor.en.js":"45ddc00eb16e","Js/tageditor.en.js":"dc13482a67f8","Js/tageditornew.en.js":"b11be3ff22c6","Js/tagsuggestions.en.js":"bd6ec908f2a7","Js/unlimited-transpiled.en.js":"f26a1d5f3365","Js/wmd.en.js":"033a0412fcae","Js/snippet-javascript-codemirror.en.js":"ae1dcf38deb7"}); 72 StackExchange.using("gps", function() { 73 StackExchange.gps.init(false); 74 }); 75 </script> 76 <noscript id="noscript-css"><style>body,.s-topbar{margin-top:1.9em}</style></noscript> 77 </head> 78 <body class="question-page unified-theme"> 79 <div id="notify-container"></div> 80 <div id="custom-header"></div> 81 82 83 <header class="s-topbar ps-fixed t0 l0 js-top-bar"> 84 <div class="s-topbar--container"> 85 <a href="#" class="s-topbar--menu-btn js-left-sidebar-toggle" role="menuitem" aria-haspopup="true" aria-controls="left-sidebar" aria-expanded="false"><span></span></a> 86 <div class="topbar-dialog leftnav-dialog js-leftnav-dialog dno"> 87 <div class="left-sidebar js-unpinned-left-sidebar" data-can-be="left-sidebar" data-is-here-when="sm"></div> 88 </div> 89 <a href="https://stackoverflow.com" class="s-topbar--logo js-gps-track" 90 data-gps-track="top_nav.click({is_current:false, location:2, destination:8})"> 91 <span class="-img _glyph">Stack Overflow</span> 92 </a> 93 94 95 96 <ol class="s-navigation" role="presentation"> 97 98 <li class="md:d-none"> 99 <a href="https://stackoverflow.co/" class="s-navigation--item js-gps-track" 100 data-gps-track="top_nav.products.click({location:2, destination:7})" 101 data-ga="["top navigation","about menu click",null,null,null]">About</a> 102 </li> 103 104 <li> 105 <a href="#" 106 class="s-navigation--item js-gps-track js-products-menu" 107 aria-controls="products-popover" 108 data-controller="s-popover" 109 data-action="s-popover#toggle" 110 data-s-popover-placement="bottom" 111 data-s-popover-toggle-class="is-selected" 112 data-gps-track="top_nav.products.click({location:2, destination:1})" 113 data-ga="["top navigation","products menu click",null,null,null]"> 114 Products 115 </a> 116 </li> 117 118 <li class="md:d-none"> 119 <a href="https://stackoverflow.co/teams/" class="s-navigation--item js-gps-track" 120 data-gps-track="top_nav.products.click({location:2, destination:7})" 121 data-ga="["top navigation","learn more - teams",null,null,null]">For Teams</a> 122 </li> 123 </ol> 124 <div class="s-popover ws2 mtn2 p0" 125 id="products-popover" 126 role="menu" 127 aria-hidden="true"> 128 <div class="s-popover--arrow"></div> 129 <ol class="list-reset s-anchors s-anchors__inherit"> 130 <li class="m6"> 131 <a href="/questions" class="bar-sm p6 d-block h:bg-black-225 js-gps-track" 132 data-gps-track="top_nav.products.click({location:2, destination:2})" 133 data-ga="["top navigation","public qa submenu click",null,null,null]"> 134 <span class="fs-body1 d-block">Stack Overflow</span> 135 <span class="fs-caption d-block fc-black-400">Public questions & answers</span> 136 </a> 137 </li> 138 <li class="m6"> 139 <a href="https://stackoverflow.co/teams/" class="bar-sm p6 d-block h:bg-black-225 js-gps-track" 140 data-gps-track="top_nav.products.click({location:2, destination:3})" 141 data-ga="["top navigation","teams submenu click",null,null,null]"> 142 <span class="fs-body1 d-block">Stack Overflow for Teams</span> 143 <span class="fs-caption d-block fc-black-400">Where developers & technologists share private knowledge with coworkers</span> 144 </a> 145 </li> 146 <li class="m6"> 147 <a href="https://stackoverflow.co/talent/" class="bar-sm p6 d-block h:bg-black-225 js-gps-track" 148 data-gps-track="top_nav.products.click({location:2, destination:5})" 149 data-ga="["top navigation","talent submenu click",null,null,null]"> 150 <span class="fs-body1 d-block">Talent</span> 151 <span class="fs-caption d-block fc-black-400"> 152 Build your employer brand 153 </span> 154 </a> 155 </li> 156 <li class="m6"> 157 <a href="https://stackoverflow.co/advertising/" class="bar-sm p6 d-block h:bg-black-225 js-gps-track" 158 data-gps-track="top_nav.products.click({location:2, destination:6})" 159 data-ga="["top navigation","advertising submenu click",null,null,null]"> 160 <span class="fs-body1 d-block">Advertising</span> 161 <span class="fs-caption d-block fc-black-400">Reach developers & technologists worldwide</span> 162 </a> 163 </li> 164 <li class="bt bc-black-200 py6 px6 bbr-md"> 165 <a href="https://stackoverflow.co/labs/" class="bar-sm p6 d-block h:bg-black-225 js-gps-track" 166 data-gps-track="top_nav.products.click({location:2, destination:7})" 167 data-ga="["top navigation","labs submenu click",null,null,null]"> 168 <span class="fs-body1 d-block">Labs</span> 169 <span class="fs-caption d-block fc-black-400">The future of collective knowledge sharing</span> 170 </a> 171 </li> 172 <li class="bg-black-100 bt bc-black-200 py6 px6 bbr-md"> 173 <a href="https://stackoverflow.co/" class="fc-black-400 d-block py6 px6 h:fc-black-600 js-gps-track" 174 data-gps-track="top_nav.products.click({location:2, destination:7})" 175 data-ga="["top navigation","about submenu click",null,null,null]">About the company</a> 176 </li> 177 </ol> 178 </div> 179 180 181 <form id="search" role="search" action=/search class="s-topbar--searchbar js-searchbar " autocomplete="off"> 182 <div class="s-topbar--searchbar--input-group"> 183 <input name="q" 184 type="text" 185 role="combobox" 186 placeholder="Search…" 187 value="" 188 autocomplete="off" 189 maxlength="240" 190 class="s-input s-input__search js-search-field " 191 aria-label="Search" 192 aria-controls="top-search" 193 data-controller="s-popover" 194 data-action="focus->s-popover#show" 195 data-s-popover-placement="bottom-start" /> 196 <svg aria-hidden="true" class="s-input-icon s-input-icon__search svg-icon iconSearch" width="18" height="18" viewBox="0 0 18 18"><path d="m18 16.5-5.14-5.18h-.35a7 7 0 1 0-1.19 1.19v.35L16.5 18l1.5-1.5ZM12 7A5 5 0 1 1 2 7a5 5 0 0 1 10 0Z"/></svg> 197 <div class="s-popover p0 wmx100 wmn4 sm:wmn-initial js-top-search-popover" id="top-search" role="menu"> 198 <div class="s-popover--arrow"></div> 199 <div class="js-spinner p24 d-flex ai-center jc-center d-none"> 200 <div class="s-spinner s-spinner__sm fc-orange-400"> 201 <div class="v-visible-sr">Loading…</div> 202 </div> 203 </div> 204 205 <span class="v-visible-sr js-screen-reader-info"></span> 206 <div class="js-ac-results overflow-y-auto hmx3 d-none"></div> 207 208 <div class="js-search-hints" aria-describedby="Tips for searching"></div> 209 </div> 210 </div> 211 </form> 212 213 <nav class="h100 ml-auto overflow-x-auto pr12"> 214 <ol class="s-topbar--content" role="menubar"> 215 216 217 218 <li class="js-topbar-dialog-corral" role="presentation"> 219 220 221 <div class="topbar-dialog siteSwitcher-dialog dno" role="menu"> 222 <div class="header fw-wrap"> 223 <h3 class="flex--item"> 224 <a href="https://stackoverflow.com">current community</a> 225 </h3> 226 <div class="flex--item fl1"> 227 <div class="ai-center d-flex jc-end"> 228 <button 229 class="js-close-button s-btn s-btn__muted p0 ml8 d-none sm:d-block" 230 type="button" 231 aria-label="Close" 232 > 233 <svg aria-hidden="true" class="svg-icon iconClear" width="18" height="18" viewBox="0 0 18 18"><path d="M15 4.41 13.59 3 9 7.59 4.41 3 3 4.41 7.59 9 3 13.59 4.41 15 9 10.41 13.59 15 15 13.59 10.41 9 15 4.41Z"/></svg> 234 </button> 235 </div> 236 </div> 237 </div> 238 <div class="modal-content bg-blue-200 current-site-container"> 239 <ul class="current-site "> 240 <li class="d-flex"> 241 <div class="fl1"> 242 <a href="https://stackoverflow.com" 243 class="current-site-link site-link js-gps-track d-flex gs8 gsx" 244 data-id="1" 245 data-gps-track="site_switcher.click({ item_type:3 })"> 246 <div class="favicon favicon-stackoverflow site-icon flex--item" title="Stack Overflow"></div> 247 <span class="flex--item fl1"> 248 Stack Overflow 249 </span> 250 </a> 251 252 </div> 253 <div class="related-links"> 254 <a href="https://stackoverflow.com/help" class="js-gps-track" data-gps-track="site_switcher.click({ item_type:14 })">help</a> 255 <a href="https://chat.stackoverflow.com/?tab=site&host=stackoverflow.com" class="js-gps-track" data-gps-track="site_switcher.click({ item_type:6 })">chat</a> 256 </div> 257 258 </li> 259 <li class="related-site d-flex"> 260 <div class="L-shaped-icon-container"> 261 <span class="L-shaped-icon"></span> 262 </div> 263 264 <a href="https://meta.stackoverflow.com" 265 class=" site-link js-gps-track d-flex gs8 gsx" 266 data-id="552" 267 data-gps-track="site.switch({ target_site:552, item_type:3 }),site_switcher.click({ item_type:4 })"> 268 <div class="favicon favicon-stackoverflowmeta site-icon flex--item" title="Meta Stack Overflow"></div> 269 <span class="flex--item fl1"> 270 Meta Stack Overflow 271 </span> 272 </a> 273 274 </li> 275 </ul> 276 </div> 277 278 <div class="header" id="your-communities-header"> 279 <h3> 280 your communities </h3> 281 282 </div> 283 <div class="modal-content" id="your-communities-section"> 284 285 <div class="call-to-login"> 286 <a href="https://stackoverflow.com/users/signup?ssrc=site_switcher&returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2f20626994%2fhow-to-calculate-the-inverse-of-the-normal-cumulative-distribution-function-in-p" class="login-link js-gps-track" data-gps-track="site_switcher.click({ item_type:10 })">Sign up</a> or <a href="https://stackoverflow.com/users/login?ssrc=site_switcher&returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2f20626994%2fhow-to-calculate-the-inverse-of-the-normal-cumulative-distribution-function-in-p" class="login-link js-gps-track" data-gps-track="site_switcher.click({ item_type:11 })">log in</a> to customize your list. </div> 287 </div> 288 289 <div class="header"> 290 <h3><a href="https://stackexchange.com/sites">more stack exchange communities</a> 291 </h3> 292 <a href="https://stackoverflow.blog" class="float-right">company blog</a> 293 </div> 294 <div class="modal-content"> 295 <div class="child-content"></div> 296 </div> 297 </div> 298 299 </li> 300 301 <li role="none"><button class="s-topbar--item s-btn s-btn__icon s-btn__muted d-none sm:d-inline-flex js-searchbar-trigger" role="menuitem" aria-label="Search" aria-haspopup="true" aria-controls="search" title="Click to show search"><svg aria-hidden="true" class="svg-icon iconSearch" width="18" height="18" viewBox="0 0 18 18"><path d="m18 16.5-5.14-5.18h-.35a7 7 0 1 0-1.19 1.19v.35L16.5 18l1.5-1.5ZM12 7A5 5 0 1 1 2 7a5 5 0 0 1 10 0Z"/></svg></button></li> 302 <li role="none"> 303 <a href="https://stackoverflow.com/users/login?ssrc=head&returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2f20626994%2fhow-to-calculate-the-inverse-of-the-normal-cumulative-distribution-function-in-p" class="s-topbar--item s-topbar--item__unset s-btn s-btn__outlined ws-nowrap js-gps-track" role="menuitem" rel="nofollow" 304 data-gps-track="login.click" data-ga="["top navigation","login button click",null,null,null]">Log in</a> 305 </li> 306 <li role="none"><a href="https://stackoverflow.com/users/signup?ssrc=head&returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2f20626994%2fhow-to-calculate-the-inverse-of-the-normal-cumulative-distribution-function-in-p" class="s-topbar--item s-topbar--item__unset ml4 s-btn s-btn__filled ws-nowrap" role="menuitem" rel="nofollow" data-ga="["sign up","Sign Up Navigation","Header",null,null]">Sign up</a></li> 307 </ol> 308 </nav> 309 310 311 </div> 312 </header> 313 314 <script> 315 StackExchange.ready(function () { StackExchange.topbar.init(); }); 316 StackExchange.scrollPadding.setPaddingTop(50, 10); 317 </script> 318 319 320 321 322 323 <div class="container"> 324 325 326 <div id="left-sidebar" data-is-here-when="md lg" class="left-sidebar js-pinned-left-sidebar ps-relative"> 327 <div class="left-sidebar--sticky-container js-sticky-leftnav"> 328 <nav role="navigation"> 329 <ol class="nav-links"> 330 <li> 331 <ol class="nav-links"> 332 333 334 <li class="ps-relative" aria-current="false"> 335 336 337 <a 338 href="/" 339 class="pl8 js-gps-track nav-links--link -link__with-icon" 340 341 data-gps-track="top_nav.click({is_current: false, location:2, destination:8, has_activity_notification:False})" 342 aria-controls="" data-controller="" data-s-popover-placement="right" 343 aria-current="false" 344 data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never" 345 > 346 <svg aria-hidden="true" class="svg-icon iconHome" width="18" height="18" viewBox="0 0 18 18"><path d="M15 10v5a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-5H0l9-9 9 9h-3Zm-8 1v6h4v-6H7Z"/></svg> <span class="-link--channel-name pl6">Home</span> 347 </a> 348 </li> 349 350 351 352 353 <li class="ps-relative youarehere" aria-current="true"> 354 355 356 <a id="nav-questions" 357 href="/questions" 358 class="pl8 js-gps-track nav-links--link -link__with-icon" 359 360 data-gps-track="top_nav.click({is_current: true, location:2, destination:1, has_activity_notification:False})" 361 aria-controls="" data-controller="" data-s-popover-placement="right" 362 aria-current="false" 363 data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never" 364 > 365 <svg aria-hidden="true" class="svg-icon iconQuestion" width="18" height="18" viewBox="0 0 18 18"><path d="m4 15-3 3V4c0-1.1.9-2 2-2h12c1.09 0 2 .91 2 2v9c0 1.09-.91 2-2 2H4Zm7.75-3.97c.72-.83.98-1.86.98-2.94 0-1.65-.7-3.22-2.3-3.83a4.41 4.41 0 0 0-3.02 0 3.8 3.8 0 0 0-2.32 3.83c0 1.29.35 2.29 1.03 3a3.8 3.8 0 0 0 2.85 1.07c.62 0 1.2-.11 1.71-.34.65.44 1 .68 1.06.7.23.13.46.23.7.3l.59-1.13a5.2 5.2 0 0 1-1.28-.66Zm-1.27-.9a5.4 5.4 0 0 0-1.5-.8l-.45.9c.33.12.66.29.98.5-.2.07-.42.11-.65.11-.61 0-1.12-.23-1.52-.68-.86-1-.86-3.12 0-4.11.8-.9 2.35-.9 3.15 0 .9 1.01.86 3.03-.01 4.08Z"/></svg> <span class="-link--channel-name pl6">Questions</span> 366 </a> 367 </li> 368 369 370 371 372 373 374 <li class="ps-relative" aria-current="false"> 375 376 377 <a 378 href="/tags" 379 class="pl8 js-gps-track nav-links--link -link__with-icon" 380 381 data-gps-track="top_nav.click({is_current: false, location:2, destination:2, has_activity_notification:False})" 382 aria-controls="" data-controller="" data-s-popover-placement="right" 383 aria-current="false" 384 data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never" 385 > 386 <svg aria-hidden="true" class="svg-icon iconTags" width="18" height="18" viewBox="0 0 18 18"><path d="M9.24 1a3 3 0 0 0-2.12.88l-5.7 5.7a2 2 0 0 0-.38 2.31 3 3 0 0 1 .67-1.01l6-6A3 3 0 0 1 9.83 2H14a3 3 0 0 1 .79.1A2 2 0 0 0 13 1H9.24Z" opacity=".4"/><path d="M9.83 3a2 2 0 0 0-1.42.59l-6 6a2 2 0 0 0 0 2.82L6.6 16.6a2 2 0 0 0 2.82 0l6-6A2 2 0 0 0 16 9.17V5a2 2 0 0 0-2-2H9.83ZM12 9a2 2 0 1 1 0-4 2 2 0 0 1 0 4Z"/></svg> <span class="-link--channel-name pl6">Tags</span> 387 </a> 388 </li> 389 390 391 <li class="pb24"></li> 392 393 394 395 396 <li class="ps-relative" aria-current="false"> 397 398 399 <a id="nav-users" 400 href="/users" 401 class="pl8 js-gps-track nav-links--link -link__with-icon" 402 403 data-gps-track="top_nav.click({is_current: false, location:2, destination:3, has_activity_notification:False})" 404 aria-controls="" data-controller="" data-s-popover-placement="right" 405 aria-current="false" 406 data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never" 407 > 408 <svg aria-hidden="true" class="svg-icon iconPeople" width="18" height="18" viewBox="0 0 18 18"><path d="M17 14c0 .44-.45 1-1 1H9a1 1 0 0 1-1-1H2c-.54 0-1-.56-1-1 0-2.63 3-4 3-4s.23-.4 0-1c-.84-.62-1.06-.59-1-3 .06-2.42 1.37-3 2.5-3s2.44.58 2.5 3c.06 2.41-.16 2.38-1 3-.23.59 0 1 0 1s1.55.71 2.42 2.09c.78-.72 1.58-1.1 1.58-1.1s.23-.4 0-1c-.84-.61-1.06-.58-1-3 .06-2.41 1.37-3 2.5-3s2.44.59 2.5 3c.05 2.42-.16 2.39-1 3-.23.6 0 1 0 1s3 1.38 3 4Z"/></svg> <span class="-link--channel-name pl6">Users</span> 409 </a> 410 </li> 411 412 413 414 415 <li class="ps-relative" aria-current="false"> 416 417 418 <a id="nav-companies" 419 href="https://stackoverflow.com/jobs/companies?so_medium=stackoverflow&so_source=SiteNav" 420 class="pl8 js-gps-track nav-links--link -link__with-icon" 421 422 data-gps-track="top_nav.click({is_current: false, location:2, destination:12, has_activity_notification:False})" 423 aria-controls="" data-controller="" data-s-popover-placement="right" 424 aria-current="false" 425 data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never" 426 > 427 <svg aria-hidden="true" class="svg-icon iconBriefcase" width="18" height="18" viewBox="0 0 18 18"><path d="M5 4a1 1 0 0 1 1-1h6a1 1 0 0 1 1 1v1h1a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V7c0-1.1.9-2 2-2h1V4Zm7 0H6v1h6V4Z"/></svg> <span class="-link--channel-name pl6">Companies</span> 428 </a> 429 </li> 430 431 432 433 <li class="ml8 mt32 mb8"> 434 <div class="d-flex jc-space-between ai-center"> 435 <a 436 class="s-link d-flex fl-grow1 fc-black-400 h:fc-black-600 fs-fine js-collectives-navcta-toggle" 437 href="javascript:void(0)" 438 role="button" 439 aria-controls="popover-discover-collectives" 440 data-controller="s-popover" 441 data-action="s-popover#toggle" 442 data-s-popover-placement="top" 443 data-s-popover-toggle-class="is-selected" 444 data-gps-track="top_nav.click({is_current:false, location:2, destination:17})" 445 > 446 <div class="flex--item fl-grow1 tt-uppercase fc-black-600 fw-bold">Collectives</div> 447 <div class="flex--item px12"> 448 <svg aria-hidden="true" class="svg-icon iconPlusSm" width="14" height="14" viewBox="0 0 14 14"><path d="M8 2H6v4H2v2h4v4h2V8h4V6H8V2Z"/></svg> </div> 449 </a> 450 451 </div> 452 453 </li> 454 455 456 <li class="ps-relative" aria-current="false"> 457 458 459 <a id="nav-collective-discover" 460 href="/collectives" 461 class="pl8 ai-center js-collectives-navcta-toggle js-gps-track nav-links--link -link__with-icon" 462 463 data-gps-track="top_nav.click({is_current: false, location:2, destination:18, has_activity_notification:False})" 464 aria-controls="" data-controller="" data-s-popover-placement="right" 465 aria-current="false" 466 data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never" 467 > 468 <svg aria-hidden="true" class="mt-auto fc-orange-400 svg-icon iconStarVerified" width="18" height="18" viewBox="0 0 18 18"><path d="M9.86.89a1.14 1.14 0 0 0-1.72 0l-.5.58c-.3.35-.79.48-1.23.33l-.72-.25a1.14 1.14 0 0 0-1.49.85l-.14.76c-.1.45-.45.8-.9.9l-.76.14c-.67.14-1.08.83-.85 1.49l.25.72c.15.44.02.92-.33 1.23l-.58.5a1.14 1.14 0 0 0 0 1.72l.58.5c.35.3.48.79.33 1.23l-.25.72c-.23.66.18 1.35.85 1.49l.76.14c.45.1.8.45.9.9l.14.76c.14.67.83 1.08 1.49.85l.72-.25c.44-.15.92-.02 1.23.33l.5.58c.46.52 1.26.52 1.72 0l.5-.58c.3-.35.79-.48 1.23-.33l.72.25c.66.23 1.35-.18 1.49-.85l.14-.76c.1-.45.45-.8.9-.9l.76-.14c.67-.14 1.08-.83.85-1.49l-.25-.72c-.15-.44-.02-.92.33-1.23l.58-.5c.52-.46.52-1.26 0-1.72l-.58-.5c-.35-.3-.48-.79-.33-1.23l.25-.72a1.14 1.14 0 0 0-.85-1.49l-.76-.14c-.45-.1-.8-.45-.9-.9l-.14-.76a1.14 1.14 0 0 0-1.49-.85l-.72.25c-.44.15-.92.02-1.23-.33l-.5-.58Zm-.49 2.67L10.6 6.6c.05.15.19.24.34.25l3.26.22c.36.03.5.48.23.71l-2.5 2.1a.4.4 0 0 0-.14.4l.8 3.16a.4.4 0 0 1-.6.44L9.2 12.13a.4.4 0 0 0-.42 0l-2.77 1.74a.4.4 0 0 1-.6-.44l.8-3.16a.4.4 0 0 0-.13-.4l-2.5-2.1a.4.4 0 0 1 .22-.7l3.26-.23a.4.4 0 0 0 .34-.25l1.22-3.03a.4.4 0 0 1 .74 0Z"/></svg> <span class="-link--channel-name pl6">Explore Collectives</span> 469 </a> 470 </li> 471 472 473 <li class="ml8 mt32 mb8"> 474 <a href="javascript:void(0)" 475 class="s-link s-link d-flex fl-grow1 fc-black-400 h:fc-black-600 fs-fine" 476 role="button" 477 aria-controls="popover-labs-left-nav" 478 data-controller="s-popover" 479 data-action="s-popover#toggle" 480 data-s-popover-placement="top" 481 data-s-popover-toggle-class="is-selected" 482 > 483 <div class="flex--item fl-grow1 tt-uppercase fc-black-600 fw-bold">Labs</div> 484 <div class="flex--item px12"> 485 <svg aria-hidden="true" class="svg-icon iconInfoSm" width="14" height="14" viewBox="0 0 14 14"><path d="M7 1a6 6 0 1 1 0 12A6 6 0 0 1 7 1Zm1 10V6H6v5h2Zm0-6V3H6v2h2Z"/></svg> 486 </div> 487 </a> 488 </li> 489 490 491 <li class="ps-relative" aria-current="false"> 492 493 494 <a id="nav-labs-discussions" 495 href="/collectives/beta/discussions" 496 class="pl8 ai-center js-gps-track nav-links--link -link__with-icon" 497 498 data-gps-track="top_nav.click({is_current: false, location:2, destination:24, has_activity_notification:False})" 499 aria-controls="" data-controller="" data-s-popover-placement="right" 500 aria-current="false" 501 data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never" 502 > 503 <svg aria-hidden="true" class="fc-black-400 w16 svg-icon iconSpeechBubble" width="18" height="18" viewBox="0 0 18 18"><path d="m4 15-3 3V4c0-1.1.9-2 2-2h12a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H4Z"/></svg> <span class="-link--channel-name pl6">Discussions</span> 504 </a> 505 </li> 506 507 </ol> 508 </li> 509 510 511 512 513 514 <li class="js-freemium-cta ps-relative"> 515 516 <div class="fs-fine tt-uppercase fc-black-600 fw-bold ml8 mt16 mb8">Teams</div> 517 518 <div class="bt bl bb bc-black-200 p12 pb6 fc-black-500 blr-sm overflow-hidden"> 519 <strong class="fc-black-600 mb6">Stack Overflow for Teams</strong> 520 – Start collaborating and sharing organizational knowledge. 521 522 <img class="wmx100 mx-auto my8 h-auto d-block" width="139" height="114" src="https://cdn.sstatic.net/Img/teams/teams-illo-free-sidebar-promo.svg?v=47faa659a05e" alt=""> 523 524 <a href="https://try.stackoverflow.co/why-teams/?utm_source=so-owned&utm_medium=side-bar&utm_campaign=campaign-38&utm_content=cta" 525 class="w100 s-btn s-btn__filled s-btn__xs bg-orange-400 js-gps-track" 526 data-gps-track="teams.create.left-sidenav.click({ Action: 6 })" 527 data-ga="["teams left navigation - anonymous","left nav free cta","stackoverflow.com/teams/create/free",null,null]">Create a free Team</a> 528 <a href="https://stackoverflow.co/teams/" 529 class="w100 s-btn s-btn__muted s-btn__xs js-gps-track" 530 data-gps-track="teams.create.left-sidenav.click({ Action: 5 })" 531 data-ga="["teams left navigation - anonymous","left nav free cta","stackoverflow.com/teams",null,null]">Why Teams?</a> 532 533 </div> 534 </li> 535 536 537 <li class="d-flex ai-center jc-space-between ml8 mt32 mb8 js-create-team-cta d-none"> 538 <a href="javascript:void(0)" 539 class="s-link d-flex fl-grow1 fc-black-400 h:fc-black-600 fs-fine js-gps-track" 540 role="button" 541 aria-controls="popover-teams-create-cta" 542 data-controller="s-popover" 543 data-action="s-popover#toggle" 544 data-s-popover-placement="bottom-start" 545 data-s-popover-toggle-class="is-selected" 546 data-gps-track="teams.create.left-sidenav.click({ Action: ShowInfo })" 547 data-ga="["teams left navigation - anonymous","left nav show teams info",null,null,null]" 548 > 549 <div class="flex--item fl-grow1 fc-black-600 fw-bold tt-uppercase">Teams</div> 550 <div class="flex--item px12"> 551 <svg aria-hidden="true" class="svg-icon iconPlusSm" width="14" height="14" viewBox="0 0 14 14"><path d="M8 2H6v4H2v2h4v4h2V8h4V6H8V2Z"/></svg> 552 </div> 553 </a> 554 </li> 555 <li class="ps-relative js-create-team-cta d-none"> 556 <a href="https://stackoverflowteams.com/teams/create/free/?utm_source=so-owned&utm_medium=side-bar&utm_campaign=campaign-38&utm_content=cta" 557 class="pl8 js-gps-track nav-links--link" 558 title="Stack Overflow for Teams is a private, secure spot for your organization's questions and answers." 559 data-gps-track="teams.create.left-sidenav.click({ Action: FreemiumTeamsCreateClick })" 560 data-ga="["teams left navigation - anonymous","left nav team click","stackoverflow.com/teams/create/free",null,null]"> 561 <div class="d-flex ai-center"> 562 <div class="flex--item s-avatar va-middle bg-orange-400"> 563 <div class="s-avatar--letter mtn1"> 564 <svg aria-hidden="true" class="svg-icon iconBriefcaseSm" width="14" height="14" viewBox="0 0 14 14"><path d="M4 3a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v1h.5c.83 0 1.5.67 1.5 1.5v5c0 .83-.67 1.5-1.5 1.5h-7A1.5 1.5 0 0 1 2 10.5v-5C2 4.67 2.67 4 3.5 4H4V3Zm5 1V3H5v1h4Z"/></svg> 565 </div> 566 <svg aria-hidden="true" class="native s-avatar--badge svg-icon iconShieldXSm" width="9" height="10" viewBox="0 0 9 10"><path fill="var(--white)" d="M0 1.84 4.5 0 9 1.84v3.17C9 7.53 6.3 10 4.5 10 2.7 10 0 7.53 0 5.01V1.84Z"/><path fill="var(--black-400)" d="M1 2.5 4.5 1 8 2.5v2.51C8 7.34 5.34 9 4.5 9 3.65 9 1 7.34 1 5.01V2.5Zm2.98 3.02L3.2 7h2.6l-.78-1.48a.4.4 0 0 1 .15-.38c.34-.24.73-.7.73-1.14 0-.71-.5-1.23-1.41-1.23-.92 0-1.39.52-1.39 1.23 0 .44.4.9.73 1.14.12.08.18.23.15.38Z"/></svg> 567 </div> 568 <div class="flex--item pl6"> 569 Create free Team 570 </div> 571 </div> 572 </a> 573 </li> 574 575 </ol> 576 </nav> 577 </div> 578 579 580 <div class="s-popover ws2" id="popover-discover-collectives" role="menu"> 581 <div class="s-popover--arrow"></div> 582 <div> 583 <svg aria-hidden="true" class="fc-orange-400 float-right ml24 svg-spot spotCollective" width="48" height="48" viewBox="0 0 48 48"><path d="M25.5 7a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5ZM14 18.25c0-.69.56-1.25 1.25-1.25h22.5c.69 0 1.25.56 1.25 1.25V37.5a1 1 0 0 1-1.6.8l-4.07-3.05a1.25 1.25 0 0 0-.75-.25H15.25c-.69 0-1.25-.56-1.25-1.25v-15.5ZM7 24.5a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0ZM25.5 48a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5ZM48 24.5a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0Z" opacity=".2"/><path d="M21 3.5a3.5 3.5 0 1 1 7 0 3.5 3.5 0 0 1-7 0ZM24.5 2a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3ZM0 23.5a3.5 3.5 0 1 1 7 0 3.5 3.5 0 0 1-7 0ZM3.5 22a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3ZM21 44.5a3.5 3.5 0 1 1 7 0 3.5 3.5 0 0 1-7 0Zm3.5-1.5a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3Zm20-23a3.5 3.5 0 1 0 0 7 3.5 3.5 0 0 0 0-7ZM43 23.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Zm-23.23-3.14a1 1 0 0 1-.13 1.4l-2.08 1.74 2.08 1.73a1 1 0 1 1-1.28 1.54l-2.42-2.02a1.63 1.63 0 0 1 0-2.5l2.42-2.02a1 1 0 0 1 1.4.13Zm7.59 1.41a1 1 0 1 1 1.28-1.54l2.42 2.02c.78.65.78 1.85 0 2.5l-2.42 2.02a1 1 0 1 1-1.28-1.54l2.08-1.73-2.08-1.73ZM24.12 18a1 1 0 0 1 .87 1.12l-1 8a1 1 0 1 1-1.98-.24l1-8a1 1 0 0 1 1.11-.87Zm-11.87-5C11.01 13 10 14 10 15.25v15.5c0 1.24 1 2.25 2.25 2.25h17.33c.06 0 .11.02.15.05l4.07 3.05a2 2 0 0 0 3.2-1.6V15.25c0-1.24-1-2.25-2.25-2.25h-22.5ZM12 15.25c0-.14.11-.25.25-.25h22.5c.14 0 .25.11.25.25V34.5l-4.07-3.05a2.2 2.2 0 0 0-1.35-.45H12.25a.25.25 0 0 1-.25-.25v-15.5Zm7.24-10.68a1 1 0 1 0-.48-1.94A22.04 22.04 0 0 0 2.91 17.7a1 1 0 1 0 1.92.58 20.04 20.04 0 0 1 14.4-13.72Zm11.05-1.66a1 1 0 0 0-.58 1.92c6.45 1.92 11.54 7 13.46 13.46a1 1 0 1 0 1.92-.58 22.05 22.05 0 0 0-14.8-14.8ZM4.57 28.76a1 1 0 0 0-1.94.48 22.03 22.03 0 0 0 16.13 16.13 1 1 0 1 0 .48-1.94A20.03 20.03 0 0 1 4.57 28.76Zm40.8.48a1 1 0 1 0-1.94-.48 20.04 20.04 0 0 1-13.72 14.41 1 1 0 0 0 .58 1.92 22.04 22.04 0 0 0 15.08-15.85Z"/></svg> 584 <h5 class="pt4 fw-bold">Collectives™ on Stack Overflow</h5> 585 <p class="my16 fs-caption fc-black-500">Find centralized, trusted content and collaborate around the technologies you use most.</p> 586 <a href="/collectives" 587 class="js-gps-track s-btn s-btn__filled s-btn__xs" 588 data-gps-track="top_nav.click({is_current:false, location:2, destination:18})"> 589 Learn more about Collectives 590 </a> 591 </div> 592 </div> 593 594 <div class="s-popover ws2" 595 id="popover-teams-create-cta" 596 role="menu" 597 aria-hidden="true"> 598 <div class="s-popover--arrow"></div> 599 600 <div class="ps-relative overflow-hidden"> 601 <p class="mb2"><strong>Teams</strong></p> 602 <p class="mb12 fs-caption fc-black-400">Q&A for work</p> 603 <p class="mb12 fs-caption fc-black-500">Connect and share knowledge within a single location that is structured and easy to search.</p> 604 <a href="https://stackoverflow.co/teams/" 605 class="js-gps-track s-btn s-btn__filled s-btn__xs" 606 data-gps-track="teams.create.left-sidenav.click({ Action: CtaClick })" 607 data-ga="["teams left navigation - anonymous","left nav cta","stackoverflow.com/teams",null,null]"> 608 Learn more about Teams 609 </a> 610 </div> 611 612 <div class="ps-absolute t8 r8"> 613 <svg aria-hidden="true" class="fc-orange-400 svg-spot spotPeople" width="48" height="48" viewBox="0 0 48 48"><path d="M13.5 28a4.5 4.5 0 1 0 0-9 4.5 4.5 0 0 0 0 9ZM7 30a1 1 0 0 1 1-1h11a1 1 0 0 1 1 1v5h11v-5a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v10a2 2 0 0 1-2 2H33v5a1 1 0 0 1-1 1H20a1 1 0 0 1-1-1v-5H8a1 1 0 0 1-1-1V30Zm25-6.5a4.5 4.5 0 1 0 9 0 4.5 4.5 0 0 0-9 0ZM24.5 34a4.5 4.5 0 1 0 0-9 4.5 4.5 0 0 0 0 9Z" opacity=".2"/><path d="M16.4 26.08A6 6 0 1 0 7.53 26C5.64 26.06 4 27.52 4 29.45V40a1 1 0 0 0 1 1h9a1 1 0 1 0 0-2h-4v-7a1 1 0 1 0-2 0v7H6v-9.55c0-.73.67-1.45 1.64-1.45H16a1 1 0 0 0 .4-1.92ZM12 18a4 4 0 1 1 0 8 4 4 0 0 1 0-8Zm16.47 14a6 6 0 1 0-8.94 0A3.6 3.6 0 0 0 16 35.5V46a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1V35.5c0-1.94-1.64-3.42-3.53-3.5ZM20 28a4 4 0 1 1 8 0 4 4 0 0 1-8 0Zm-.3 6h8.6c1 0 1.7.75 1.7 1.5V45h-2v-7a1 1 0 1 0-2 0v7h-4v-7a1 1 0 1 0-2 0v7h-2v-9.5c0-.75.7-1.5 1.7-1.5ZM42 22c0 1.54-.58 2.94-1.53 4A3.5 3.5 0 0 1 44 29.45V40a1 1 0 0 1-1 1h-9a1 1 0 1 1 0-2h4v-7a1 1 0 1 1 2 0v7h2v-9.55A1.5 1.5 0 0 0 40.48 28H32a1 1 0 0 1-.4-1.92A6 6 0 1 1 42 22Zm-2 0a4 4 0 1 0-8 0 4 4 0 0 0 8 0Z"/><g opacity=".35"><path d="M17 10a1 1 0 011-1h12a1 1 0 110 2H18a1 1 0 01-1-1Zm1-5a1 1 0 100 2h12a1 1 0 100-2H18ZM14 1a1 1 0 00-1 1v12a1 1 0 001 1h5.09l4.2 4.2a1 1 0 001.46-.04l3.7-4.16H34a1 1 0 001-1V2a1 1 0 00-1-1H14Zm1 12V3h18v10h-5a1 1 0 00-.75.34l-3.3 3.7-3.74-3.75a1 1 0 00-.71-.29H15Z"/></g></svg> 614 </div> 615 </div> 616 617 <div class="s-popover ws2" 618 id="popover-labs-left-nav" 619 role="menu" 620 aria-hidden="true"> 621 <div class="s-popover--arrow"></div> 622 <svg aria-hidden="true" class="fc-black-600 mb8 svg-icon iconLabs" width="42" height="18"><path d="M11.5 13.624a.374.374 0 0 1-.37.376H5.361a.374.374 0 0 1-.37-.376V4.376c0-.207.165-.376.37-.376H6.62c.204 0 .37.169.37.376v7.611h4.138c.205 0 .371.169.371.377v1.26zm9.432.215c-.07.1-.185.161-.308.161H19.13a.376.376 0 0 1-.356-.254l-.55-1.7h-3.111l-.55 1.7a.377.377 0 0 1-.355.254h-1.494a.376.376 0 0 1-.353-.506l3.39-9.247A.376.376 0 0 1 16.103 4h1.13c.158 0 .299.099.353.247l3.39 9.247a.376.376 0 0 1-.045.345zm-4.157-7.386l-1.219 3.531h2.266l-1.047-3.53zm13.335 5.71a.37.37 0 0 0-.003.524c.956.971 2.047 1.313 3.486 1.313 1.014 0 1.92-.265 2.582-.788.67-.53 1.063-1.306 1.063-2.255 0-.855-.268-1.622-.867-2.145-.456-.41-1.008-.633-1.89-.767l-1.037-.153c-.377-.057-.672-.19-.832-.332-.146-.132-.221-.315-.221-.568 0-.309.11-.56.306-.737.199-.179.518-.312.986-.312.708 0 1.254.151 1.726.601a.37.37 0 0 0 .516-.004l.883-.87a.37.37 0 0 0-.008-.534C35.942 4.334 35.004 4 33.721 4c-1.016 0-1.872.292-2.479.836-.61.548-.935 1.32-.935 2.207 0 .82.243 1.502.781 2.01h.001c.468.437 1.135.716 1.93.826l1.072.153c.508.073.647.147.795.286l.008.007c.14.125.234.34.234.67 0 .332-.124.567-.344.73-.235.174-.617.293-1.165.293-.867 0-1.49-.185-2.066-.76a.37.37 0 0 0-.522-.003l-.92.908zM22.37 14a.374.374 0 0 1-.37-.376V4.376c0-.207.166-.376.37-.376h3.543c.913 0 1.697.264 2.257.78.564.519.863 1.259.863 2.129 0 .845-.377 1.524-.87 1.947.57.433 1.01 1.145 1.01 2.157 0 .941-.317 1.702-.894 2.224-.57.517-1.354.763-2.225.763H22.37zm3.543-1.977c.96 0 .959-1.01.959-1.01s0-1.013-.959-1.013H24v2.023h1.913zm-.115-4.063c1.074 0 1.074-1.015 1.074-1.015s0-1.016-1.074-1.016H24V7.96h1.798z" fill="var(--black-600)"/><path d="M0 4v10a4 4 0 0 0 4 4h34a4 4 0 0 0 4-4V4a4 4 0 0 0-4-4H4a4 4 0 0 0-4 4zm4-2h34a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2z" fill="var(--black-600)"/></svg> 623 <p class="fs-caption">Get early access and see previews of new features.</p> 624 <a class="s-btn s-btn__filled s-btn__xs s-btn__icon fs-fine" href="https://stackoverflow.co/labs/"><svg aria-hidden="true" class="svg-icon iconShareSm" width="14" height="14" viewBox="0 0 14 14"><path d="M5 1H3a2 2 0 0 0-2 2v8c0 1.1.9 2 2 2h8a2 2 0 0 0 2-2V9h-2v2H3V3h2V1Zm2 0h6v6h-2V4.5L6.5 9 5 7.5 9.5 3H7V1Z"/></svg> Learn more about Labs</a> 625 </div> 626 627 628 </div> 629 630 631 632 <div id="content" class="snippet-hidden"> 633 634 635 636 <div itemprop="mainEntity" itemscope itemtype="https://schema.org/Question"> 637 <link itemprop="image" href="https://cdn.sstatic.net/Sites/stackoverflow/Img/apple-touch-icon.png?v=c78bd457575a"> 638 639 <div class="inner-content clearfix"> 640 641 642 643 <div id="question-header" class="d-flex sm:fd-column"> 644 <h1 itemprop="name" class="fs-headline1 ow-break-word mb8 flex--item fl1"><a href="/questions/20626994/how-to-calculate-the-inverse-of-the-normal-cumulative-distribution-function-in-p" class="question-hyperlink">How to calculate the inverse of the normal cumulative distribution function in python?</a></h1> 645 <div class="ml12 aside-cta flex--item print:d-none sm:ml0 sm:mb12 sm:order-first sm:as-end"> 646 <a href="/questions/ask" class="ws-nowrap s-btn s-btn__filled"> 647 Ask Question 648 </a> 649 650 </div> 651 </div> 652 <div class="d-flex fw-wrap pb8 mb16 bb bc-black-200"> 653 <div class="flex--item ws-nowrap mr16 mb8" title="2013-12-17 05:57:49Z"> 654 <span class="fc-black-400 mr2">Asked</span> 655 <time itemprop="dateCreated" datetime="2013-12-17T05:57:49">9 years, 11 months ago</time> 656 </div> 657 <div class="flex--item ws-nowrap mr16 mb8"> 658 <span class="fc-black-400 mr2">Modified</span> 659 <a href="?lastactivity" class="s-link s-link__inherit" title="2022-08-15 14:05:56Z">1 year, 3 months ago</a> 660 </div> 661 <div class="flex--item ws-nowrap mb8" title="Viewed 199,067 times"> 662 <span class="fc-black-400 mr2">Viewed</span> 663 199k times 664 </div> 665 </div> 666 <div id="mainbar" role="main" aria-label="question and answers"> 667 668 669 <div class="question js-question" data-questionid="20626994" data-position-on-page="0" data-score="107" id="question"> 670 <style> 671 </style> 672 <div class="js-zone-container zone-container-main"> 673 <div id="dfp-tlb" class="everyonelovesstackoverflow everyoneloves__top-leaderboard everyoneloves__leaderboard"></div> 674 <div class="js-report-ad-button-container " style="width: 728px"></div> 675 </div> 676 677 <div class="post-layout "> 678 <div class="votecell post-layout--left"> 679 <div class="js-voting-container d-flex jc-center fd-column ai-stretch gs4 fc-black-300" data-post-id="20626994" data-referrer="None"> 680 <button class="js-vote-up-btn flex--item s-btn ba bar-pill c-pointer as-center bc-black-225 fc-black-500 h:bg-theme-primary-200" 681 data-controller="s-tooltip" 682 data-s-tooltip-placement="right" 683 title="This question shows research effort; it is useful and clear" 684 aria-pressed="false" 685 aria-label="Up vote" 686 data-selected-classes="fc-theme-primary bc-theme-primary bg-theme-primary-100" 687 data-unselected-classes="bc-black-225 fc-black-500 h:bg-theme-primary-200"> 688 <svg aria-hidden="true" class="svg-icon iconArrowUp" width="18" height="18" viewBox="0 0 18 18"><path d="M1 12h16L9 4l-8 8Z"/></svg> 689 </button> 690 <div class="js-vote-count flex--item d-flex fd-column ai-center fc-theme-body-font fw-bold fs-subheading py4" 691 itemprop="upvoteCount" 692 data-value="107"> 693 107 694 </div> 695 <button class="js-vote-down-btn flex--item mb8 s-btn ba bar-pill c-pointer as-center bc-black-225 fc-black-500 h:bg-theme-primary-200" 696 data-controller="s-tooltip" 697 data-s-tooltip-placement="right" 698 title="This question does not show any research effort; it is unclear or not useful" 699 aria-pressed="false" 700 aria-label="Down vote" 701 data-selected-classes="fc-theme-primary bc-theme-primary bg-theme-primary-100" 702 data-unselected-classes="bc-black-225 fc-black-500 h:bg-theme-primary-200"> 703 <svg aria-hidden="true" class="svg-icon iconArrowDown" width="18" height="18" viewBox="0 0 18 18"><path d="M1 6h16l-8 8-8-8Z"/></svg> 704 </button> 705 706 707 708 <button class="js-saves-btn s-btn s-btn__unset c-pointer py4" 709 type="button" 710 id="saves-btn-20626994" 711 data-controller="s-tooltip" 712 data-s-tooltip-placement="right" 713 data-s-popover-placement="" 714 title="Save this question." 715 aria-pressed="false" 716 data-post-id="20626994" 717 data-post-type-id="1" 718 data-user-privilege-for-post-click="0" 719 aria-controls="" 720 data-s-popover-auto-show="false" 721 > 722 <svg aria-hidden="true" class="fc-theme-primary-400 js-saves-btn-selected d-none svg-icon iconBookmark" width="18" height="18" viewBox="0 0 18 18"><path d="M3 17V3c0-1.1.9-2 2-2h8a2 2 0 0 1 2 2v14l-6-4-6 4Z"/></svg> 723 <svg aria-hidden="true" class="js-saves-btn-unselected svg-icon iconBookmarkAlt" width="18" height="18" viewBox="0 0 18 18"><path d="m9 10.6 4 2.66V3H5v10.26l4-2.66ZM3 17V3c0-1.1.9-2 2-2h8a2 2 0 0 1 2 2v14l-6-4-6 4Z"/></svg> 724 </button> 725 726 727 728 729 730 731 732 733 734 <a class="js-post-issue flex--item s-btn s-btn__unset c-pointer py6 mx-auto" href="/posts/20626994/timeline" data-shortcut="T" data-ks-title="timeline" data-controller="s-tooltip" data-s-tooltip-placement="right" title="Show activity on this post." aria-label="Timeline"><svg aria-hidden="true" class="mln2 mr0 svg-icon iconHistory" width="19" height="18" viewBox="0 0 19 18"><path d="M3 9a8 8 0 1 1 3.73 6.77L8.2 14.3A6 6 0 1 0 5 9l3.01-.01-4 4-4-4h3L3 9Zm7-4h1.01L11 9.36l3.22 2.1-.6.93L10 10V5Z"/></svg></a> 735 736 </div> 737 738 </div> 739 740 741 742 <div class="postcell post-layout--right"> 743 744 <div class="s-prose js-post-body" itemprop="text"> 745 746 <p>How do I calculate the inverse of the cumulative distribution function (CDF) of the normal distribution in Python?</p> 747 748 <p>Which library should I use? Possibly scipy? </p> 749 </div> 750 751 <div class="mt24 mb12"> 752 <div class="post-taglist d-flex gs4 gsy fd-column"> 753 <div class="d-flex ps-relative fw-wrap"> 754 755 <ul class='ml0 list-ls-none js-post-tag-list-wrapper d-inline'><li class='d-inline mr4 js-post-tag-list-item'><a href="/questions/tagged/python" class="post-tag" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class='d-inline mr4 js-post-tag-list-item'><a href="/questions/tagged/scipy" class="post-tag" title="show questions tagged 'scipy'" aria-label="show questions tagged 'scipy'" rel="tag" aria-labelledby="tag-scipy-tooltip-container">scipy</a></li><li class='d-inline mr4 js-post-tag-list-item'><a href="/questions/tagged/normal-distribution" class="post-tag" title="show questions tagged 'normal-distribution'" aria-label="show questions tagged 'normal-distribution'" rel="tag" aria-labelledby="tag-normal-distribution-tooltip-container">normal-distribution</a></li></ul> 756 </div> 757 </div> 758 </div> 759 760 <div class="mb0 "> 761 <div class="mt16 d-flex gs8 gsy fw-wrap jc-end ai-start pt4 mb16"> 762 <div class="flex--item mr16 fl1 w96"> 763 764 765 766 <div class="js-post-menu pt2" data-post-id="20626994" data-post-type-id="1"> 767 768 <div class="d-flex gs8 s-anchors s-anchors__muted fw-wrap"> 769 770 <div class="flex--item"> 771 <a href="/q/20626994" 772 rel="nofollow" 773 itemprop="url" 774 class="js-share-link js-gps-track" 775 title="Short permalink to this question" 776 data-gps-track="post.click({ item: 2, priv: 0, post_type: 1 })" 777 data-controller="se-share-sheet" 778 data-se-share-sheet-title="Share a link to this question" 779 data-se-share-sheet-subtitle="" 780 data-se-share-sheet-post-type="question" 781 data-se-share-sheet-social="facebook twitter devto" 782 data-se-share-sheet-location="1" 783 data-se-share-sheet-license-url="https%3a%2f%2fcreativecommons.org%2flicenses%2fby-sa%2f3.0%2f" 784 data-se-share-sheet-license-name="CC BY-SA 3.0" 785 data-s-popover-placement="bottom-start">Share</a> 786 </div> 787 788 789 790 <div class="flex--item"> 791 <button type="button" 792 id="btnFollowPost-20626994" class="s-btn s-btn__link js-follow-post js-follow-question js-gps-track" 793 data-gps-track="post.click({ item: 14, priv: 0, post_type: 1 })" 794 data-controller="s-tooltip " data-s-tooltip-placement="bottom" 795 data-s-popover-placement="bottom" aria-controls="" 796 title="Follow this question to receive notifications"> 797 Follow 798 </button> 799 </div> 800 801 802 803 804 805 806 </div> 807 <div class="js-menu-popup-container"></div> 808 </div> 809 </div> 810 811 <div class="post-signature flex--item"> 812 <div class="user-info user-hover"> 813 <div class="user-action-time"> 814 <a href="/posts/20626994/revisions" title="show all edits to this post" 815 class="js-gps-track" 816 data-gps-track="post.click({ item: 4, priv: 0, post_type: 1 })">edited <span title='2015-03-31 14:52:45Z' class='relativetime'>Mar 31, 2015 at 14:52</span></a> 817 </div> 818 <div class="user-gravatar32"> 819 <a href="/users/3139711/knedlsepp"><div class="gravatar-wrapper-32"><img src="https://i.stack.imgur.com/MemQ8.jpg?s=64&g=1" alt="knedlsepp's user avatar" width="32" height="32" class="bar-sm"></div></a> 820 </div> 821 <div class="user-details"> 822 <a href="/users/3139711/knedlsepp">knedlsepp</a> 823 <div class="-flair"> 824 <span class="reputation-score" title="reputation score " dir="ltr">6,065</span><span title="3 gold badges" aria-hidden="true"><span class="badge1"></span><span class="badgecount">3</span></span><span class="v-visible-sr">3 gold badges</span><span title="20 silver badges" aria-hidden="true"><span class="badge2"></span><span class="badgecount">20</span></span><span class="v-visible-sr">20 silver badges</span><span title="41 bronze badges" aria-hidden="true"><span class="badge3"></span><span class="badgecount">41</span></span><span class="v-visible-sr">41 bronze badges</span> 825 </div> 826 </div> 827 </div> 828 </div> 829 <div class="post-signature owner flex--item"> 830 <div class="user-info "> 831 <div class="user-action-time"> 832 asked <span title='2013-12-17 05:57:49Z' class='relativetime'>Dec 17, 2013 at 5:57</span> 833 </div> 834 <div class="user-gravatar32"> 835 <a href="/users/1624752/yueyoum"><div class="gravatar-wrapper-32"><img src="https://www.gravatar.com/avatar/deabf064baf56e064e1d71fabb49b676?s=64&d=identicon&r=PG" alt="Yueyoum's user avatar" width="32" height="32" class="bar-sm"></div></a> 836 </div> 837 <div class="user-details" itemprop="author" itemscope itemtype="http://schema.org/Person"> 838 <a href="/users/1624752/yueyoum">Yueyoum</a><span class="d-none" itemprop="name">Yueyoum</span> 839 <div class="-flair"> 840 <span class="reputation-score" title="reputation score " dir="ltr">2,853</span><span title="5 gold badges" aria-hidden="true"><span class="badge1"></span><span class="badgecount">5</span></span><span class="v-visible-sr">5 gold badges</span><span title="23 silver badges" aria-hidden="true"><span class="badge2"></span><span class="badgecount">23</span></span><span class="v-visible-sr">23 silver badges</span><span title="26 bronze badges" aria-hidden="true"><span class="badge3"></span><span class="badgecount">26</span></span><span class="v-visible-sr">26 bronze badges</span> 841 </div> 842 </div> 843 </div> 844 845 846 </div> 847 </div> 848 </div> 849 850 </div> 851 852 853 854 855 <span class="d-none" itemprop="commentCount">3</span> 856 <div class="post-layout--right js-post-comments-component"> 857 <div id="comments-20626994" class="comments js-comments-container bt bc-black-200 mt12 " data-post-id="20626994" data-min-length="15"> 858 <ul class="comments-list js-comments-list" 859 data-remaining-comments-count="0" 860 data-canpost="false" 861 data-cansee="true" 862 data-comments-unavailable="false" 863 data-addlink-disabled="true"> 864 865 <li id="comment-30873309" class="comment js-comment " data-comment-id="30873309" data-comment-owner-id="1217358" data-comment-score="1"> 866 <div class="js-comment-actions comment-actions"> 867 <div class="comment-score js-comment-score js-comment-edit-hide"> 868 <span title="number of 'useful comment' votes received" 869 class="cool">1</span> 870 </div> 871 </div> 872 <div class="comment-text js-comment-text-and-form"> 873 <div class="comment-body js-comment-edit-hide"> 874 875 <span class="comment-copy">Do you mean the inverse Gaussian distribution (<a href="http://en.wikipedia.org/wiki/Inverse_Gaussian_distribution" rel="nofollow noreferrer">en.wikipedia.org/wiki/Inverse_Gaussian_distribution</a>), or the inverse of the cumulative distribution function of the normal distribution (<a href="http://en.wikipedia.org/wiki/Normal_distribution" rel="nofollow noreferrer">en.wikipedia.org/wiki/Normal_distribution</a>), or something else?</span> 876 877 <div class="d-inline-flex ai-center"> 878 – <a href="/users/1217358/warren-weckesser" 879 title="111,515 reputation" 880 class="comment-user">Warren Weckesser</a> 881 </div> 882 <span class="comment-date" dir="ltr"><span title='2013-12-17 06:30:48Z, License: CC BY-SA 3.0' class='relativetime-clean'>Dec 17, 2013 at 6:30</span></span> 883 <span title="this comment was edited 1 time"> 884 <svg aria-hidden="true" class="va-text-bottom o50 svg-icon iconPencilSm" width="14" height="14" viewBox="0 0 14 14"><path fill="#F1B600" d="m2 10.12 6.37-6.43 1.88 1.88L3.88 12H2v-1.88Z"/><path fill="#E87C87" d="m11.1 1.71 1.13 1.12c.2.2.2.51 0 .71L11.1 4.7 9.21 2.86l1.17-1.15c.2-.2.51-.2.71 0Z"/></svg> 885 </span> 886 </div> 887 </div> 888 </li> 889 <li id="comment-30873351" class="comment js-comment " data-comment-id="30873351" data-comment-owner-id="1624752" data-comment-score="0"> 890 <div class="js-comment-actions comment-actions"> 891 <div class="comment-score js-comment-score js-comment-edit-hide"> 892 </div> 893 </div> 894 <div class="comment-text js-comment-text-and-form"> 895 <div class="comment-body js-comment-edit-hide"> 896 897 <span class="comment-copy">@WarrenWeckesser the second one: inverse of the cumulative distribution function of the normal distribution</span> 898 899 <div class="d-inline-flex ai-center"> 900 – <a href="/users/1624752/yueyoum" 901 title="2,853 reputation" 902 class="comment-user owner">Yueyoum</a> 903 </div> 904 <span class="comment-date" dir="ltr"><span title='2013-12-17 06:32:40Z, License: CC BY-SA 3.0' class='relativetime-clean'>Dec 17, 2013 at 6:32</span></span> 905 <span title="this comment was edited 1 time"> 906 <svg aria-hidden="true" class="va-text-bottom o50 svg-icon iconPencilSm" width="14" height="14" viewBox="0 0 14 14"><path fill="#F1B600" d="m2 10.12 6.37-6.43 1.88 1.88L3.88 12H2v-1.88Z"/><path fill="#E87C87" d="m11.1 1.71 1.13 1.12c.2.2.2.51 0 .71L11.1 4.7 9.21 2.86l1.17-1.15c.2-.2.51-.2.71 0Z"/></svg> 907 </span> 908 </div> 909 </div> 910 </li> 911 <li id="comment-30873496" class="comment js-comment " data-comment-id="30873496" data-comment-owner-id="1624752" data-comment-score="1"> 912 <div class="js-comment-actions comment-actions"> 913 <div class="comment-score js-comment-score js-comment-edit-hide"> 914 <span title="number of 'useful comment' votes received" 915 class="cool">1</span> 916 </div> 917 </div> 918 <div class="comment-text js-comment-text-and-form"> 919 <div class="comment-body js-comment-edit-hide"> 920 921 <span class="comment-copy">@WarrenWeckesser i mean the python version of "normsinv" function in excel.</span> 922 923 <div class="d-inline-flex ai-center"> 924 – <a href="/users/1624752/yueyoum" 925 title="2,853 reputation" 926 class="comment-user owner">Yueyoum</a> 927 </div> 928 <span class="comment-date" dir="ltr"><span title='2013-12-17 06:39:22Z, License: CC BY-SA 3.0' class='relativetime-clean'>Dec 17, 2013 at 6:39</span></span> 929 </div> 930 </div> 931 </li> 932 933 </ul> 934 </div> 935 936 <div id="comments-link-20626994" data-rep=50 data-anon=true> 937 <a class="js-add-link comments-link disabled-link" title="Use comments to ask for more information or suggest improvements. Avoid answering questions in comments." href="#" role="button">Add a comment</a> 938 <span class="js-link-separator dno"> | </span> 939 <a class="js-show-link comments-link dno" title="Expand to show all comments on this post" href=# onclick="" role="button"></a> 940 </div> 941 </div> 942 </div> 943 944 </div> 945 946 947 <div class="js-zone-container zone-container-responsive"> 948 <div id="dfp-isb" class="everyonelovesstackoverflow everyoneloves__inline-sidebar mx-auto"></div> 949 <div class="js-report-ad-button-container mx-auto" style="width: 300px"></div> 950 </div> 951 952 953 954 <div id="answers"> 955 <a name="tab-top"></a> 956 <div id="answers-header"> 957 <div class="answers-subheader d-flex ai-center mb8"> 958 <div class="flex--item fl1"> 959 <h2 class="mb0" data-answercount="3"> 960 3 Answers 961 <span style="display:none;" itemprop="answerCount">3</span> 962 </h2> 963 </div> 964 <div class="flex--item"> 965 966 967 <div class="d-flex g4 gsx ai-center sm:fd-column sm:ai-start"> 968 <div class="d-flex fd-column ai-end sm:ai-start"> 969 <label class="flex--item fs-caption" for="answer-sort-dropdown-select-menu"> 970 Sorted by: 971 </label> 972 <a 973 class="js-sort-preference-change s-link flex--item fs-fine d-none" 974 data-value="ScoreDesc" 975 href="/questions/20626994/how-to-calculate-the-inverse-of-the-normal-cumulative-distribution-function-in-p?answertab=scoredesc#tab-top" 976 > 977 Reset to default 978 </a> 979 </div> 980 <div class="flex--item s-select"> 981 <select id="answer-sort-dropdown-select-menu"> 982 <option 983 value=scoredesc 984 selected=selected 985 > 986 Highest score (default) 987 </option> 988 <option 989 value=trending 990 > 991 Trending (recent votes count more) 992 </option> 993 <option 994 value=modifieddesc 995 > 996 Date modified (newest first) 997 </option> 998 <option 999 value=createdasc 1000 > 1001 Date created (oldest first) 1002 </option> 1003 </select> 1004 </div> 1005 </div> 1006 1007 1008 </div> 1009 </div> 1010 1011 </div> 1012 1013 1014 1015 <a name="20627638"></a> 1016 <div id="answer-20627638" class="answer js-answer accepted-answer js-accepted-answer" data-answerid="20627638" data-parentid="20626994" data-score="171" data-position-on-page="1" data-highest-scored="1" data-question-has-accepted-highest-score="1" itemprop="acceptedAnswer" itemscope itemtype="https://schema.org/Answer"> 1017 <div class="post-layout"> 1018 <div class="votecell post-layout--left"> 1019 <div class="js-voting-container d-flex jc-center fd-column ai-stretch gs4 fc-black-300" data-post-id="20627638" data-referrer="None"> 1020 <button class="js-vote-up-btn flex--item s-btn ba bar-pill c-pointer as-center bc-black-225 fc-black-500 h:bg-theme-primary-200" 1021 data-controller="s-tooltip" 1022 data-s-tooltip-placement="right" 1023 title="This answer is useful" 1024 aria-pressed="false" 1025 aria-label="Up vote" 1026 data-selected-classes="fc-theme-primary bc-theme-primary bg-theme-primary-100" 1027 data-unselected-classes="bc-black-225 fc-black-500 h:bg-theme-primary-200"> 1028 <svg aria-hidden="true" class="svg-icon iconArrowUp" width="18" height="18" viewBox="0 0 18 18"><path d="M1 12h16L9 4l-8 8Z"/></svg> 1029 </button> 1030 <div class="js-vote-count flex--item d-flex fd-column ai-center fc-theme-body-font fw-bold fs-subheading py4" 1031 itemprop="upvoteCount" 1032 data-value="171"> 1033 171 1034 </div> 1035 <button class="js-vote-down-btn flex--item mb8 s-btn ba bar-pill c-pointer as-center bc-black-225 fc-black-500 h:bg-theme-primary-200" 1036 data-controller="s-tooltip" 1037 data-s-tooltip-placement="right" 1038 title="This answer is not useful" 1039 aria-pressed="false" 1040 aria-label="Down vote" 1041 data-selected-classes="fc-theme-primary bc-theme-primary bg-theme-primary-100" 1042 data-unselected-classes="bc-black-225 fc-black-500 h:bg-theme-primary-200"> 1043 <svg aria-hidden="true" class="svg-icon iconArrowDown" width="18" height="18" viewBox="0 0 18 18"><path d="M1 6h16l-8 8-8-8Z"/></svg> 1044 </button> 1045 1046 1047 1048 <button class="js-saves-btn s-btn s-btn__unset c-pointer py4" 1049 type="button" 1050 id="saves-btn-20627638" 1051 data-controller="s-tooltip" 1052 data-s-tooltip-placement="right" 1053 data-s-popover-placement="" 1054 title="Save this answer." 1055 aria-pressed="false" 1056 data-post-id="20627638" 1057 data-post-type-id="2" 1058 data-user-privilege-for-post-click="0" 1059 aria-controls="" 1060 data-s-popover-auto-show="false" 1061 > 1062 <svg aria-hidden="true" class="fc-theme-primary-400 js-saves-btn-selected d-none svg-icon iconBookmark" width="18" height="18" viewBox="0 0 18 18"><path d="M3 17V3c0-1.1.9-2 2-2h8a2 2 0 0 1 2 2v14l-6-4-6 4Z"/></svg> 1063 <svg aria-hidden="true" class="js-saves-btn-unselected svg-icon iconBookmarkAlt" width="18" height="18" viewBox="0 0 18 18"><path d="m9 10.6 4 2.66V3H5v10.26l4-2.66ZM3 17V3c0-1.1.9-2 2-2h8a2 2 0 0 1 2 2v14l-6-4-6 4Z"/></svg> 1064 </button> 1065 1066 1067 1068 1069 1070 1071 1072 <div class="js-accepted-answer-indicator flex--item fc-green-400 py6 mtn8" data-s-tooltip-placement="right" title="Loading when this answer was accepted…" tabindex="0" role="note" aria-label="Accepted"> 1073 <div class="ta-center"> 1074 <svg aria-hidden="true" class="svg-icon iconCheckmarkLg" width="36" height="36" viewBox="0 0 36 36"><path d="m6 14 8 8L30 6v8L14 30l-8-8v-8Z"/></svg> 1075 </div> 1076 </div> 1077 1078 1079 <a class="js-post-issue flex--item s-btn s-btn__unset c-pointer py6 mx-auto" href="/posts/20627638/timeline" data-shortcut="T" data-ks-title="timeline" data-controller="s-tooltip" data-s-tooltip-placement="right" title="Show activity on this post." aria-label="Timeline"><svg aria-hidden="true" class="mln2 mr0 svg-icon iconHistory" width="19" height="18" viewBox="0 0 19 18"><path d="M3 9a8 8 0 1 1 3.73 6.77L8.2 14.3A6 6 0 1 0 5 9l3.01-.01-4 4-4-4h3L3 9Zm7-4h1.01L11 9.36l3.22 2.1-.6.93L10 10V5Z"/></svg></a> 1080 1081 </div> 1082 1083 </div> 1084 1085 1086 1087 <div class="answercell post-layout--right"> 1088 1089 <div class="s-prose js-post-body" itemprop="text"> 1090 <p><a href="http://support.microsoft.com/kb/826772" rel="noreferrer">NORMSINV</a> (mentioned in a comment) is the inverse of the CDF of the standard normal distribution. Using <code>scipy</code>, you can compute this with the <code>ppf</code> method of the <a href="http://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.norm.html" rel="noreferrer"><code>scipy.stats.norm</code></a> object. The acronym <code>ppf</code> stands for <a href="http://www.itl.nist.gov/div898/handbook/eda/section3/eda362.htm#PPF" rel="noreferrer"><em>percent point function</em></a>, which is another name for the <a href="https://en.wikipedia.org/wiki/Quantile_function" rel="noreferrer"><em>quantile function</em></a>.</p> 1091 <pre><code>In [20]: from scipy.stats import norm 1092 1093 In [21]: norm.ppf(0.95) 1094 Out[21]: 1.6448536269514722 1095 </code></pre> 1096 <p>Check that it is the inverse of the CDF:</p> 1097 <pre><code>In [34]: norm.cdf(norm.ppf(0.95)) 1098 Out[34]: 0.94999999999999996 1099 </code></pre> 1100 <p>By default, <code>norm.ppf</code> uses mean=0 and stddev=1, which is the "standard" normal distribution. You can use a different mean and standard deviation by specifying the <code>loc</code> and <code>scale</code> arguments, respectively.</p> 1101 <pre><code>In [35]: norm.ppf(0.95, loc=10, scale=2) 1102 Out[35]: 13.289707253902945 1103 </code></pre> 1104 <p>If you look at the source code for <code>scipy.stats.norm</code>, you'll find that the <code>ppf</code> method ultimately calls <a href="http://docs.scipy.org/doc/scipy/reference/generated/scipy.special.ndtri.html" rel="noreferrer"><code>scipy.special.ndtri</code></a>. So to compute the inverse of the CDF of the standard normal distribution, you could use that function directly:</p> 1105 <pre><code>In [43]: from scipy.special import ndtri 1106 1107 In [44]: ndtri(0.95) 1108 Out[44]: 1.6448536269514722 1109 </code></pre> 1110 <p><code>ndtri</code> is <em>much</em> faster than <code>norm.ppf</code>:</p> 1111 <pre><code>In [46]: %timeit norm.ppf(0.95) 1112 240 µs ± 1.75 µs per loop (mean ± std. dev. of 7 runs, 1,000 loops each) 1113 1114 In [47]: %timeit ndtri(0.95) 1115 1.47 µs ± 1.3 ns per loop (mean ± std. dev. of 7 runs, 1,000,000 loops each) 1116 </code></pre> 1117 </div> 1118 <div class="mt24"> 1119 <div class="d-flex fw-wrap ai-start jc-end gs8 gsy"> 1120 <time itemprop="dateCreated" datetime="2013-12-17T06:44:02"></time> 1121 <div class="flex--item mr16" style="flex: 1 1 100px;"> 1122 1123 1124 1125 <div class="js-post-menu pt2" data-post-id="20627638" data-post-type-id="2"> 1126 1127 <div class="d-flex gs8 s-anchors s-anchors__muted fw-wrap"> 1128 1129 <div class="flex--item"> 1130 <a href="/a/20627638" 1131 rel="nofollow" 1132 itemprop="url" 1133 class="js-share-link js-gps-track" 1134 title="Short permalink to this answer" 1135 data-gps-track="post.click({ item: 2, priv: 0, post_type: 2 })" 1136 data-controller="se-share-sheet" 1137 data-se-share-sheet-title="Share a link to this answer" 1138 data-se-share-sheet-subtitle="" 1139 data-se-share-sheet-post-type="answer" 1140 data-se-share-sheet-social="facebook twitter devto" 1141 data-se-share-sheet-location="2" 1142 data-se-share-sheet-license-url="https%3a%2f%2fcreativecommons.org%2flicenses%2fby-sa%2f4.0%2f" 1143 data-se-share-sheet-license-name="CC BY-SA 4.0" 1144 data-s-popover-placement="bottom-start">Share</a> 1145 </div> 1146 1147 1148 1149 <div class="flex--item"> 1150 <button type="button" 1151 id="btnFollowPost-20627638" class="s-btn s-btn__link js-follow-post js-follow-answer js-gps-track" 1152 data-gps-track="post.click({ item: 14, priv: 0, post_type: 2 })" 1153 data-controller="s-tooltip " data-s-tooltip-placement="bottom" 1154 data-s-popover-placement="bottom" aria-controls="" 1155 title="Follow this answer to receive notifications"> 1156 Follow 1157 </button> 1158 </div> 1159 1160 1161 1162 1163 1164 1165 </div> 1166 <div class="js-menu-popup-container"></div> 1167 </div> 1168 </div> 1169 <div class="post-signature flex--item fl0"> 1170 <div class="user-info "> 1171 <div class="user-action-time"> 1172 <a href="/posts/20627638/revisions" title="show all edits to this post" 1173 class="js-gps-track" 1174 data-gps-track="post.click({ item: 4, priv: 0, post_type: 2 })">edited <span title='2022-08-15 14:05:56Z' class='relativetime'>Aug 15, 2022 at 14:05</span></a> 1175 </div> 1176 <div class="user-gravatar32"> 1177 1178 </div> 1179 <div class="user-details"> 1180 1181 <div class="-flair"> 1182 1183 </div> 1184 </div> 1185 </div> 1186 </div> 1187 1188 1189 <div class="post-signature flex--item fl0"> 1190 <div class="user-info "> 1191 <div class="user-action-time"> 1192 answered <span title='2013-12-17 06:44:02Z' class='relativetime'>Dec 17, 2013 at 6:44</span> 1193 </div> 1194 <div class="user-gravatar32"> 1195 <a href="/users/1217358/warren-weckesser"><div class="gravatar-wrapper-32"><img src="https://www.gravatar.com/avatar/d2aafb97833979e3668c61d36e697bfc?s=64&d=identicon&r=PG" alt="Warren Weckesser's user avatar" width="32" height="32" class="bar-sm"></div></a> 1196 </div> 1197 <div class="user-details" itemprop="author" itemscope itemtype="http://schema.org/Person"> 1198 <a href="/users/1217358/warren-weckesser">Warren Weckesser</a><span class="d-none" itemprop="name">Warren Weckesser</span> 1199 <div class="-flair"> 1200 <span class="reputation-score" title="reputation score 111,515" dir="ltr">112k</span><span title="19 gold badges" aria-hidden="true"><span class="badge1"></span><span class="badgecount">19</span></span><span class="v-visible-sr">19 gold badges</span><span title="196 silver badges" aria-hidden="true"><span class="badge2"></span><span class="badgecount">196</span></span><span class="v-visible-sr">196 silver badges</span><span title="215 bronze badges" aria-hidden="true"><span class="badge3"></span><span class="badgecount">215</span></span><span class="v-visible-sr">215 bronze badges</span> 1201 </div> 1202 </div> 1203 </div> 1204 1205 1206 </div> 1207 </div> 1208 1209 1210 </div> 1211 1212 </div> 1213 1214 1215 1216 1217 <span class="d-none" itemprop="commentCount">4</span> 1218 <div class="post-layout--right js-post-comments-component"> 1219 <div id="comments-20627638" class="comments js-comments-container bt bc-black-200 mt12 " data-post-id="20627638" data-min-length="15"> 1220 <ul class="comments-list js-comments-list" 1221 data-remaining-comments-count="0" 1222 data-canpost="false" 1223 data-cansee="true" 1224 data-comments-unavailable="false" 1225 data-addlink-disabled="true"> 1226 1227 <li id="comment-41064090" class="comment js-comment " data-comment-id="41064090" data-comment-owner-id="1670078" data-comment-score="29"> 1228 <div class="js-comment-actions comment-actions"> 1229 <div class="comment-score js-comment-score js-comment-edit-hide"> 1230 <span title="number of 'useful comment' votes received" 1231 class="hot">29</span> 1232 </div> 1233 </div> 1234 <div class="comment-text js-comment-text-and-form"> 1235 <div class="comment-body js-comment-edit-hide"> 1236 1237 <span class="comment-copy">I always think "percent point function" (ppf) is a terrible name. Most people in statistics just use "quantile function".</span> 1238 1239 <div class="d-inline-flex ai-center"> 1240 – <a href="/users/1670078/william-zhang" 1241 title="699 reputation" 1242 class="comment-user">William Zhang</a> 1243 </div> 1244 <span class="comment-date" dir="ltr"><span title='2014-10-04 00:44:33Z, License: CC BY-SA 3.0' class='relativetime-clean'>Oct 4, 2014 at 0:44</span></span> 1245 </div> 1246 </div> 1247 </li> 1248 <li id="comment-116623338" class="comment js-comment " data-comment-id="116623338" data-comment-owner-id="1391660" data-comment-score="0"> 1249 <div class="js-comment-actions comment-actions"> 1250 <div class="comment-score js-comment-score js-comment-edit-hide"> 1251 </div> 1252 </div> 1253 <div class="comment-text js-comment-text-and-form"> 1254 <div class="comment-body js-comment-edit-hide"> 1255 1256 <span class="comment-copy">Don't you need to specify the mean and the std on both ppf and cdf?</span> 1257 1258 <div class="d-inline-flex ai-center"> 1259 – <a href="/users/1391660/bones-felipe" 1260 title="586 reputation" 1261 class="comment-user">bones.felipe</a> 1262 </div> 1263 <span class="comment-date" dir="ltr"><span title='2021-01-29 19:23:44Z, License: CC BY-SA 4.0' class='relativetime-clean'>Jan 29, 2021 at 19:23</span></span> 1264 <span title="this comment was edited 2 times"> 1265 <svg aria-hidden="true" class="va-text-bottom o50 svg-icon iconPencilSm" width="14" height="14" viewBox="0 0 14 14"><path fill="#F1B600" d="m2 10.12 6.37-6.43 1.88 1.88L3.88 12H2v-1.88Z"/><path fill="#E87C87" d="m11.1 1.71 1.13 1.12c.2.2.2.51 0 .71L11.1 4.7 9.21 2.86l1.17-1.15c.2-.2.51-.2.71 0Z"/></svg> 1266 </span> 1267 </div> 1268 </div> 1269 </li> 1270 <li id="comment-116623958" class="comment js-comment " data-comment-id="116623958" data-comment-owner-id="1217358" data-comment-score="0"> 1271 <div class="js-comment-actions comment-actions"> 1272 <div class="comment-score js-comment-score js-comment-edit-hide"> 1273 </div> 1274 </div> 1275 <div class="comment-text js-comment-text-and-form"> 1276 <div class="comment-body js-comment-edit-hide"> 1277 1278 <span class="comment-copy">@bones.felipe, the "standard" normal distribution has mean 0 and standard deviation 1. These are the default values for the location and scale of the <code>scipy.stats.norm</code> methods.</span> 1279 1280 <div class="d-inline-flex ai-center"> 1281 – <a href="/users/1217358/warren-weckesser" 1282 title="111,515 reputation" 1283 class="comment-user">Warren Weckesser</a> 1284 </div> 1285 <span class="comment-date" dir="ltr"><span title='2021-01-29 19:55:51Z, License: CC BY-SA 4.0' class='relativetime-clean'>Jan 29, 2021 at 19:55</span></span> 1286 </div> 1287 </div> 1288 </li> 1289 <li id="comment-116630954" class="comment js-comment " data-comment-id="116630954" data-comment-owner-id="1391660" data-comment-score="0"> 1290 <div class="js-comment-actions comment-actions"> 1291 <div class="comment-score js-comment-score js-comment-edit-hide"> 1292 </div> 1293 </div> 1294 <div class="comment-text js-comment-text-and-form"> 1295 <div class="comment-body js-comment-edit-hide"> 1296 1297 <span class="comment-copy">Right, I thought I saw this <code>norm.cdf(norm.ppf(0.95, loc=10, scale=2))</code> and I thought it was weird <code>norm.cdf</code> did not have <code>loc=10</code> and <code>scale=2</code> too, I guess it should.</span> 1298 1299 <div class="d-inline-flex ai-center"> 1300 – <a href="/users/1391660/bones-felipe" 1301 title="586 reputation" 1302 class="comment-user">bones.felipe</a> 1303 </div> 1304 <span class="comment-date" dir="ltr"><span title='2021-01-30 05:33:43Z, License: CC BY-SA 4.0' class='relativetime-clean'>Jan 30, 2021 at 5:33</span></span> 1305 <span title="this comment was edited 1 time"> 1306 <svg aria-hidden="true" class="va-text-bottom o50 svg-icon iconPencilSm" width="14" height="14" viewBox="0 0 14 14"><path fill="#F1B600" d="m2 10.12 6.37-6.43 1.88 1.88L3.88 12H2v-1.88Z"/><path fill="#E87C87" d="m11.1 1.71 1.13 1.12c.2.2.2.51 0 .71L11.1 4.7 9.21 2.86l1.17-1.15c.2-.2.51-.2.71 0Z"/></svg> 1307 </span> 1308 </div> 1309 </div> 1310 </li> 1311 1312 </ul> 1313 </div> 1314 1315 <div id="comments-link-20627638" data-rep=50 data-anon=true> 1316 <a class="js-add-link comments-link disabled-link" title="Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”." href="#" role="button">Add a comment</a> 1317 <span class="js-link-separator dno"> | </span> 1318 <a class="js-show-link comments-link dno" title="Expand to show all comments on this post" href=# onclick="" role="button"></a> 1319 </div> 1320 </div> 1321 </div> 1322 </div> 1323 1324 <div class="js-zone-container zone-container-main"> 1325 <div id="dfp-mlb" class="everyonelovesstackoverflow everyoneloves__mid-leaderboard everyoneloves__leaderboard"></div> 1326 <div class="js-report-ad-button-container " style="width: 728px"></div> 1327 </div> 1328 1329 <a name="55250607"></a> 1330 <div id="answer-55250607" class="answer js-answer" data-answerid="55250607" data-parentid="20626994" data-score="39" data-position-on-page="2" data-highest-scored="0" data-question-has-accepted-highest-score="1" itemprop="suggestedAnswer" itemscope itemtype="https://schema.org/Answer"> 1331 <div class="post-layout"> 1332 <div class="votecell post-layout--left"> 1333 <div class="js-voting-container d-flex jc-center fd-column ai-stretch gs4 fc-black-300" data-post-id="55250607" data-referrer="None"> 1334 <button class="js-vote-up-btn flex--item s-btn ba bar-pill c-pointer as-center bc-black-225 fc-black-500 h:bg-theme-primary-200" 1335 data-controller="s-tooltip" 1336 data-s-tooltip-placement="right" 1337 title="This answer is useful" 1338 aria-pressed="false" 1339 aria-label="Up vote" 1340 data-selected-classes="fc-theme-primary bc-theme-primary bg-theme-primary-100" 1341 data-unselected-classes="bc-black-225 fc-black-500 h:bg-theme-primary-200"> 1342 <svg aria-hidden="true" class="svg-icon iconArrowUp" width="18" height="18" viewBox="0 0 18 18"><path d="M1 12h16L9 4l-8 8Z"/></svg> 1343 </button> 1344 <div class="js-vote-count flex--item d-flex fd-column ai-center fc-theme-body-font fw-bold fs-subheading py4" 1345 itemprop="upvoteCount" 1346 data-value="39"> 1347 39 1348 </div> 1349 <button class="js-vote-down-btn flex--item mb8 s-btn ba bar-pill c-pointer as-center bc-black-225 fc-black-500 h:bg-theme-primary-200" 1350 data-controller="s-tooltip" 1351 data-s-tooltip-placement="right" 1352 title="This answer is not useful" 1353 aria-pressed="false" 1354 aria-label="Down vote" 1355 data-selected-classes="fc-theme-primary bc-theme-primary bg-theme-primary-100" 1356 data-unselected-classes="bc-black-225 fc-black-500 h:bg-theme-primary-200"> 1357 <svg aria-hidden="true" class="svg-icon iconArrowDown" width="18" height="18" viewBox="0 0 18 18"><path d="M1 6h16l-8 8-8-8Z"/></svg> 1358 </button> 1359 1360 1361 1362 <button class="js-saves-btn s-btn s-btn__unset c-pointer py4" 1363 type="button" 1364 id="saves-btn-55250607" 1365 data-controller="s-tooltip" 1366 data-s-tooltip-placement="right" 1367 data-s-popover-placement="" 1368 title="Save this answer." 1369 aria-pressed="false" 1370 data-post-id="55250607" 1371 data-post-type-id="2" 1372 data-user-privilege-for-post-click="0" 1373 aria-controls="" 1374 data-s-popover-auto-show="false" 1375 > 1376 <svg aria-hidden="true" class="fc-theme-primary-400 js-saves-btn-selected d-none svg-icon iconBookmark" width="18" height="18" viewBox="0 0 18 18"><path d="M3 17V3c0-1.1.9-2 2-2h8a2 2 0 0 1 2 2v14l-6-4-6 4Z"/></svg> 1377 <svg aria-hidden="true" class="js-saves-btn-unselected svg-icon iconBookmarkAlt" width="18" height="18" viewBox="0 0 18 18"><path d="m9 10.6 4 2.66V3H5v10.26l4-2.66ZM3 17V3c0-1.1.9-2 2-2h8a2 2 0 0 1 2 2v14l-6-4-6 4Z"/></svg> 1378 </button> 1379 1380 1381 1382 1383 1384 1385 1386 <div class="js-accepted-answer-indicator flex--item fc-green-400 py6 mtn8 d-none" data-s-tooltip-placement="right" title="Loading when this answer was accepted…" tabindex="0" role="note" aria-label="Accepted"> 1387 <div class="ta-center"> 1388 <svg aria-hidden="true" class="svg-icon iconCheckmarkLg" width="36" height="36" viewBox="0 0 36 36"><path d="m6 14 8 8L30 6v8L14 30l-8-8v-8Z"/></svg> 1389 </div> 1390 </div> 1391 1392 1393 <a class="js-post-issue flex--item s-btn s-btn__unset c-pointer py6 mx-auto" href="/posts/55250607/timeline" data-shortcut="T" data-ks-title="timeline" data-controller="s-tooltip" data-s-tooltip-placement="right" title="Show activity on this post." aria-label="Timeline"><svg aria-hidden="true" class="mln2 mr0 svg-icon iconHistory" width="19" height="18" viewBox="0 0 19 18"><path d="M3 9a8 8 0 1 1 3.73 6.77L8.2 14.3A6 6 0 1 0 5 9l3.01-.01-4 4-4-4h3L3 9Zm7-4h1.01L11 9.36l3.22 2.1-.6.93L10 10V5Z"/></svg></a> 1394 1395 </div> 1396 1397 </div> 1398 1399 1400 1401 <div class="answercell post-layout--right"> 1402 1403 <div class="s-prose js-post-body" itemprop="text"> 1404 <p>Starting <code>Python 3.8</code>, the standard library provides the <a href="https://docs.python.org/3.8/library/statistics.html?highlight=normaldist#statistics.NormalDist" rel="noreferrer"><code>NormalDist</code></a> object as part of the <a href="https://docs.python.org/3.8/library/statistics.html" rel="noreferrer"><code>statistics</code></a> module.</p> 1405 1406 <p>It can be used to get the <strong><em>inverse cumulative distribution function</em></strong> (<strong><a href="https://docs.python.org/3.8/library/statistics.html#statistics.NormalDist.inv_cdf" rel="noreferrer"><code>inv_cdf</code></a></strong> - inverse of the <a href="https://docs.python.org/3.8/library/statistics.html#statistics.NormalDist.cdf" rel="noreferrer"><code>cdf</code></a>), also known as the <strong>quantile function</strong> or the <strong>percent-point function</strong> for a given <em>mean</em> (<code>mu</code>) and <em>standard deviation</em> (<code>sigma</code>):</p> 1407 1408 <pre><code>from statistics import NormalDist 1409 1410 NormalDist(mu=10, sigma=2).inv_cdf(0.95) 1411 # 13.289707253902943 1412 </code></pre> 1413 1414 <p>Which can be simplified for the <em>standard normal distribution</em> (<code>mu = 0</code> and <code>sigma = 1</code>):</p> 1415 1416 <pre><code>NormalDist().inv_cdf(0.95) 1417 # 1.6448536269514715 1418 </code></pre> 1419 </div> 1420 <div class="mt24"> 1421 <div class="d-flex fw-wrap ai-start jc-end gs8 gsy"> 1422 <time itemprop="dateCreated" datetime="2019-03-19T21:58:57"></time> 1423 <div class="flex--item mr16" style="flex: 1 1 100px;"> 1424 1425 1426 1427 <div class="js-post-menu pt2" data-post-id="55250607" data-post-type-id="2"> 1428 1429 <div class="d-flex gs8 s-anchors s-anchors__muted fw-wrap"> 1430 1431 <div class="flex--item"> 1432 <a href="/a/55250607" 1433 rel="nofollow" 1434 itemprop="url" 1435 class="js-share-link js-gps-track" 1436 title="Short permalink to this answer" 1437 data-gps-track="post.click({ item: 2, priv: 0, post_type: 2 })" 1438 data-controller="se-share-sheet" 1439 data-se-share-sheet-title="Share a link to this answer" 1440 data-se-share-sheet-subtitle="" 1441 data-se-share-sheet-post-type="answer" 1442 data-se-share-sheet-social="facebook twitter devto" 1443 data-se-share-sheet-location="2" 1444 data-se-share-sheet-license-url="https%3a%2f%2fcreativecommons.org%2flicenses%2fby-sa%2f4.0%2f" 1445 data-se-share-sheet-license-name="CC BY-SA 4.0" 1446 data-s-popover-placement="bottom-start">Share</a> 1447 </div> 1448 1449 1450 1451 <div class="flex--item"> 1452 <button type="button" 1453 id="btnFollowPost-55250607" class="s-btn s-btn__link js-follow-post js-follow-answer js-gps-track" 1454 data-gps-track="post.click({ item: 14, priv: 0, post_type: 2 })" 1455 data-controller="s-tooltip " data-s-tooltip-placement="bottom" 1456 data-s-popover-placement="bottom" aria-controls="" 1457 title="Follow this answer to receive notifications"> 1458 Follow 1459 </button> 1460 </div> 1461 1462 1463 1464 1465 1466 1467 </div> 1468 <div class="js-menu-popup-container"></div> 1469 </div> 1470 </div> 1471 1472 1473 <div class="post-signature flex--item fl0"> 1474 <div class="user-info user-hover"> 1475 <div class="user-action-time"> 1476 answered <span title='2019-03-19 21:58:57Z' class='relativetime'>Mar 19, 2019 at 21:58</span> 1477 </div> 1478 <div class="user-gravatar32"> 1479 <a href="/users/9297144/xavier-guihot"><div class="gravatar-wrapper-32"><img src="https://i.stack.imgur.com/WLMMD.png?s=64&g=1" alt="Xavier Guihot's user avatar" width="32" height="32" class="bar-sm"></div></a> 1480 </div> 1481 <div class="user-details" itemprop="author" itemscope itemtype="http://schema.org/Person"> 1482 <a href="/users/9297144/xavier-guihot">Xavier Guihot</a><span class="d-none" itemprop="name">Xavier Guihot</span> 1483 <div class="-flair"> 1484 <span class="reputation-score" title="reputation score 56,556" dir="ltr">56.6k</span><span title="22 gold badges" aria-hidden="true"><span class="badge1"></span><span class="badgecount">22</span></span><span class="v-visible-sr">22 gold badges</span><span title="297 silver badges" aria-hidden="true"><span class="badge2"></span><span class="badgecount">297</span></span><span class="v-visible-sr">297 silver badges</span><span title="192 bronze badges" aria-hidden="true"><span class="badge3"></span><span class="badgecount">192</span></span><span class="v-visible-sr">192 bronze badges</span> 1485 </div> 1486 </div> 1487 </div> 1488 1489 1490 </div> 1491 </div> 1492 1493 1494 </div> 1495 1496 </div> 1497 1498 1499 1500 1501 <span class="d-none" itemprop="commentCount">2</span> 1502 <div class="post-layout--right js-post-comments-component"> 1503 <div id="comments-55250607" class="comments js-comments-container bt bc-black-200 mt12 " data-post-id="55250607" data-min-length="15"> 1504 <ul class="comments-list js-comments-list" 1505 data-remaining-comments-count="0" 1506 data-canpost="false" 1507 data-cansee="true" 1508 data-comments-unavailable="false" 1509 data-addlink-disabled="true"> 1510 1511 <li id="comment-106743999" class="comment js-comment " data-comment-id="106743999" data-comment-owner-id="5437918" data-comment-score="4"> 1512 <div class="js-comment-actions comment-actions"> 1513 <div class="comment-score js-comment-score js-comment-edit-hide"> 1514 <span title="number of 'useful comment' votes received" 1515 class="cool">4</span> 1516 </div> 1517 </div> 1518 <div class="comment-text js-comment-text-and-form"> 1519 <div class="comment-body js-comment-edit-hide"> 1520 1521 <span class="comment-copy">Great tip! This allows me to drop the dependency on scipy, which I needed just for the single stats.norm.ppf method</span> 1522 1523 <div class="d-inline-flex ai-center"> 1524 – <a href="/users/5437918/jethro-cao" 1525 title="1,010 reputation" 1526 class="comment-user">Jethro Cao</a> 1527 </div> 1528 <span class="comment-date" dir="ltr"><span title='2020-02-21 16:56:27Z, License: CC BY-SA 4.0' class='relativetime-clean'>Feb 21, 2020 at 16:56</span></span> 1529 </div> 1530 </div> 1531 </li> 1532 <li id="comment-126713418" class="comment js-comment " data-comment-id="126713418" data-comment-owner-id="10824677" data-comment-score="0"> 1533 <div class="js-comment-actions comment-actions"> 1534 <div class="comment-score js-comment-score js-comment-edit-hide"> 1535 </div> 1536 </div> 1537 <div class="comment-text js-comment-text-and-form"> 1538 <div class="comment-body js-comment-edit-hide"> 1539 1540 <span class="comment-copy">can you use that to transform data with uniform distribution to normal ?</span> 1541 1542 <div class="d-inline-flex ai-center"> 1543 – <a href="/users/10824677/vanetoj" 1544 title="103 reputation" 1545 class="comment-user">vanetoj</a> 1546 </div> 1547 <span class="comment-date" dir="ltr"><span title='2022-03-31 20:51:01Z, License: CC BY-SA 4.0' class='relativetime-clean'>Mar 31, 2022 at 20:51</span></span> 1548 </div> 1549 </div> 1550 </li> 1551 1552 </ul> 1553 </div> 1554 1555 <div id="comments-link-55250607" data-rep=50 data-anon=true> 1556 <a class="js-add-link comments-link disabled-link" title="Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”." href="#" role="button">Add a comment</a> 1557 <span class="js-link-separator dno"> | </span> 1558 <a class="js-show-link comments-link dno" title="Expand to show all comments on this post" href=# onclick="" role="button"></a> 1559 </div> 1560 </div> 1561 </div> 1562 </div> 1563 1564 1565 <a name="32798562"></a> 1566 <div id="answer-32798562" class="answer js-answer" data-answerid="32798562" data-parentid="20626994" data-score="21" data-position-on-page="3" data-highest-scored="0" data-question-has-accepted-highest-score="1" itemprop="suggestedAnswer" itemscope itemtype="https://schema.org/Answer"> 1567 <div class="post-layout"> 1568 <div class="votecell post-layout--left"> 1569 <div class="js-voting-container d-flex jc-center fd-column ai-stretch gs4 fc-black-300" data-post-id="32798562" data-referrer="None"> 1570 <button class="js-vote-up-btn flex--item s-btn ba bar-pill c-pointer as-center bc-black-225 fc-black-500 h:bg-theme-primary-200" 1571 data-controller="s-tooltip" 1572 data-s-tooltip-placement="right" 1573 title="This answer is useful" 1574 aria-pressed="false" 1575 aria-label="Up vote" 1576 data-selected-classes="fc-theme-primary bc-theme-primary bg-theme-primary-100" 1577 data-unselected-classes="bc-black-225 fc-black-500 h:bg-theme-primary-200"> 1578 <svg aria-hidden="true" class="svg-icon iconArrowUp" width="18" height="18" viewBox="0 0 18 18"><path d="M1 12h16L9 4l-8 8Z"/></svg> 1579 </button> 1580 <div class="js-vote-count flex--item d-flex fd-column ai-center fc-theme-body-font fw-bold fs-subheading py4" 1581 itemprop="upvoteCount" 1582 data-value="21"> 1583 21 1584 </div> 1585 <button class="js-vote-down-btn flex--item mb8 s-btn ba bar-pill c-pointer as-center bc-black-225 fc-black-500 h:bg-theme-primary-200" 1586 data-controller="s-tooltip" 1587 data-s-tooltip-placement="right" 1588 title="This answer is not useful" 1589 aria-pressed="false" 1590 aria-label="Down vote" 1591 data-selected-classes="fc-theme-primary bc-theme-primary bg-theme-primary-100" 1592 data-unselected-classes="bc-black-225 fc-black-500 h:bg-theme-primary-200"> 1593 <svg aria-hidden="true" class="svg-icon iconArrowDown" width="18" height="18" viewBox="0 0 18 18"><path d="M1 6h16l-8 8-8-8Z"/></svg> 1594 </button> 1595 1596 1597 1598 <button class="js-saves-btn s-btn s-btn__unset c-pointer py4" 1599 type="button" 1600 id="saves-btn-32798562" 1601 data-controller="s-tooltip" 1602 data-s-tooltip-placement="right" 1603 data-s-popover-placement="" 1604 title="Save this answer." 1605 aria-pressed="false" 1606 data-post-id="32798562" 1607 data-post-type-id="2" 1608 data-user-privilege-for-post-click="0" 1609 aria-controls="" 1610 data-s-popover-auto-show="false" 1611 > 1612 <svg aria-hidden="true" class="fc-theme-primary-400 js-saves-btn-selected d-none svg-icon iconBookmark" width="18" height="18" viewBox="0 0 18 18"><path d="M3 17V3c0-1.1.9-2 2-2h8a2 2 0 0 1 2 2v14l-6-4-6 4Z"/></svg> 1613 <svg aria-hidden="true" class="js-saves-btn-unselected svg-icon iconBookmarkAlt" width="18" height="18" viewBox="0 0 18 18"><path d="m9 10.6 4 2.66V3H5v10.26l4-2.66ZM3 17V3c0-1.1.9-2 2-2h8a2 2 0 0 1 2 2v14l-6-4-6 4Z"/></svg> 1614 </button> 1615 1616 1617 1618 1619 1620 1621 1622 <div class="js-accepted-answer-indicator flex--item fc-green-400 py6 mtn8 d-none" data-s-tooltip-placement="right" title="Loading when this answer was accepted…" tabindex="0" role="note" aria-label="Accepted"> 1623 <div class="ta-center"> 1624 <svg aria-hidden="true" class="svg-icon iconCheckmarkLg" width="36" height="36" viewBox="0 0 36 36"><path d="m6 14 8 8L30 6v8L14 30l-8-8v-8Z"/></svg> 1625 </div> 1626 </div> 1627 1628 1629 <a class="js-post-issue flex--item s-btn s-btn__unset c-pointer py6 mx-auto" href="/posts/32798562/timeline" data-shortcut="T" data-ks-title="timeline" data-controller="s-tooltip" data-s-tooltip-placement="right" title="Show activity on this post." aria-label="Timeline"><svg aria-hidden="true" class="mln2 mr0 svg-icon iconHistory" width="19" height="18" viewBox="0 0 19 18"><path d="M3 9a8 8 0 1 1 3.73 6.77L8.2 14.3A6 6 0 1 0 5 9l3.01-.01-4 4-4-4h3L3 9Zm7-4h1.01L11 9.36l3.22 2.1-.6.93L10 10V5Z"/></svg></a> 1630 1631 </div> 1632 1633 </div> 1634 1635 1636 1637 <div class="answercell post-layout--right"> 1638 1639 <div class="s-prose js-post-body" itemprop="text"> 1640 <pre><code># given random variable X (house price) with population muy = 60, sigma = 40 1641 import scipy as sc 1642 import scipy.stats as sct 1643 sc.version.full_version # 0.15.1 1644 1645 #a. Find P(X<50) 1646 sct.norm.cdf(x=50,loc=60,scale=40) # 0.4012936743170763 1647 1648 #b. Find P(X>=50) 1649 sct.norm.sf(x=50,loc=60,scale=40) # 0.5987063256829237 1650 1651 #c. Find P(60<=X<=80) 1652 sct.norm.cdf(x=80,loc=60,scale=40) - sct.norm.cdf(x=60,loc=60,scale=40) 1653 1654 #d. how much top most 5% expensive house cost at least? or find x where P(X>=x) = 0.05 1655 sct.norm.isf(q=0.05,loc=60,scale=40) 1656 1657 #e. how much top most 5% cheapest house cost at least? or find x where P(X<=x) = 0.05 1658 sct.norm.ppf(q=0.05,loc=60,scale=40) 1659 </code></pre> 1660 </div> 1661 <div class="mt24"> 1662 <div class="d-flex fw-wrap ai-start jc-end gs8 gsy"> 1663 <time itemprop="dateCreated" datetime="2015-09-26T15:04:38"></time> 1664 <div class="flex--item mr16" style="flex: 1 1 100px;"> 1665 1666 1667 1668 <div class="js-post-menu pt2" data-post-id="32798562" data-post-type-id="2"> 1669 1670 <div class="d-flex gs8 s-anchors s-anchors__muted fw-wrap"> 1671 1672 <div class="flex--item"> 1673 <a href="/a/32798562" 1674 rel="nofollow" 1675 itemprop="url" 1676 class="js-share-link js-gps-track" 1677 title="Short permalink to this answer" 1678 data-gps-track="post.click({ item: 2, priv: 0, post_type: 2 })" 1679 data-controller="se-share-sheet" 1680 data-se-share-sheet-title="Share a link to this answer" 1681 data-se-share-sheet-subtitle="" 1682 data-se-share-sheet-post-type="answer" 1683 data-se-share-sheet-social="facebook twitter devto" 1684 data-se-share-sheet-location="2" 1685 data-se-share-sheet-license-url="https%3a%2f%2fcreativecommons.org%2flicenses%2fby-sa%2f3.0%2f" 1686 data-se-share-sheet-license-name="CC BY-SA 3.0" 1687 data-s-popover-placement="bottom-start">Share</a> 1688 </div> 1689 1690 1691 1692 <div class="flex--item"> 1693 <button type="button" 1694 id="btnFollowPost-32798562" class="s-btn s-btn__link js-follow-post js-follow-answer js-gps-track" 1695 data-gps-track="post.click({ item: 14, priv: 0, post_type: 2 })" 1696 data-controller="s-tooltip " data-s-tooltip-placement="bottom" 1697 data-s-popover-placement="bottom" aria-controls="" 1698 title="Follow this answer to receive notifications"> 1699 Follow 1700 </button> 1701 </div> 1702 1703 1704 1705 1706 1707 1708 </div> 1709 <div class="js-menu-popup-container"></div> 1710 </div> 1711 </div> 1712 1713 1714 <div class="post-signature flex--item fl0"> 1715 <div class="user-info "> 1716 <div class="user-action-time"> 1717 answered <span title='2015-09-26 15:04:38Z' class='relativetime'>Sep 26, 2015 at 15:04</span> 1718 </div> 1719 <div class="user-gravatar32"> 1720 <a href="/users/1125621/o0omycomputero0o"><div class="gravatar-wrapper-32"><img src="https://www.gravatar.com/avatar/c1b3328f06ea4ab079677388658dae10?s=64&d=identicon&r=PG" alt="o0omycomputero0o's user avatar" width="32" height="32" class="bar-sm"></div></a> 1721 </div> 1722 <div class="user-details" itemprop="author" itemscope itemtype="http://schema.org/Person"> 1723 <a href="/users/1125621/o0omycomputero0o">o0omycomputero0o</a><span class="d-none" itemprop="name">o0omycomputero0o</span> 1724 <div class="-flair"> 1725 <span class="reputation-score" title="reputation score " dir="ltr">3,376</span><span title="4 gold badges" aria-hidden="true"><span class="badge1"></span><span class="badgecount">4</span></span><span class="v-visible-sr">4 gold badges</span><span title="32 silver badges" aria-hidden="true"><span class="badge2"></span><span class="badgecount">32</span></span><span class="v-visible-sr">32 silver badges</span><span title="45 bronze badges" aria-hidden="true"><span class="badge3"></span><span class="badgecount">45</span></span><span class="v-visible-sr">45 bronze badges</span> 1726 </div> 1727 </div> 1728 </div> 1729 1730 1731 </div> 1732 </div> 1733 1734 1735 </div> 1736 1737 </div> 1738 1739 1740 1741 1742 <span class="d-none" itemprop="commentCount">1</span> 1743 <div class="post-layout--right js-post-comments-component"> 1744 <div id="comments-32798562" class="comments js-comments-container bt bc-black-200 mt12 " data-post-id="32798562" data-min-length="15"> 1745 <ul class="comments-list js-comments-list" 1746 data-remaining-comments-count="0" 1747 data-canpost="false" 1748 data-cansee="true" 1749 data-comments-unavailable="false" 1750 data-addlink-disabled="true"> 1751 1752 <li id="comment-76824582" class="comment js-comment " data-comment-id="76824582" data-comment-owner-id="4815313" data-comment-score="6"> 1753 <div class="js-comment-actions comment-actions"> 1754 <div class="comment-score js-comment-score js-comment-edit-hide"> 1755 <span title="number of 'useful comment' votes received" 1756 class="warm">6</span> 1757 </div> 1758 </div> 1759 <div class="comment-text js-comment-text-and-form"> 1760 <div class="comment-body js-comment-edit-hide"> 1761 1762 <span class="comment-copy">PS: You can assume 'loc' as 'mean' and 'scale' as 'standard deviation'</span> 1763 1764 <div class="d-inline-flex ai-center"> 1765 – <a href="/users/4815313/suresh2692" 1766 title="3,873 reputation" 1767 class="comment-user">Suresh2692</a> 1768 </div> 1769 <span class="comment-date" dir="ltr"><span title='2017-07-05 11:11:41Z, License: CC BY-SA 3.0' class='relativetime-clean'>Jul 5, 2017 at 11:11</span></span> 1770 </div> 1771 </div> 1772 </li> 1773 1774 </ul> 1775 </div> 1776 1777 <div id="comments-link-32798562" data-rep=50 data-anon=true> 1778 <a class="js-add-link comments-link disabled-link" title="Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”." href="#" role="button">Add a comment</a> 1779 <span class="js-link-separator dno"> | </span> 1780 <a class="js-show-link comments-link dno" title="Expand to show all comments on this post" href=# onclick="" role="button"></a> 1781 </div> 1782 </div> 1783 </div> 1784 </div> 1785 1786 1787 <aside class="s-notice s-notice__info post-notice js-post-notice mb16" role="status"> 1788 <div class="d-flex fd-column fw-nowrap"> 1789 <div class="d-flex fw-nowrap"> 1790 <div class="flex--item mr8"> 1791 <svg aria-hidden="true" class="svg-icon iconFire" width="18" height="18" viewBox="0 0 18 18"><path fill="#FF6700" d="M13.18 9c-.8.33-1.46.6-1.97 1.3A9.21 9.21 0 0 0 10 13.89a10 10 0 0 0 1.32-.8 2.53 2.53 0 0 1-.63 2.91h.78a3 3 0 0 0 1.66-.5 4.15 4.15 0 0 0 1.26-1.61c.4-.96.47-1.7.55-2.73.05-1.24-.1-2.49-.46-3.68a2 2 0 0 1-.4.91 2.1 2.1 0 0 1-.9.62Z" opacity=".6"/><path fill="#EF2E2E" d="M10.4 12.11a7.1 7.1 0 0 1 .78-1.76c.3-.47.81-.8 1.37-1.08 0 0-.05-3.27-1.55-5.27-1.5-2-3.37-2.75-4.95-2.61 0 0 4.19 2.94 1.18 5.67-2.14 1.92-3.64 3.81-3.1 5.94a4.14 4.14 0 0 0 3.1 3 4.05 4.05 0 0 1 1.08-3.89C9.42 10.92 8 9.79 8 9.79c.67.02 1.3.28 1.81.72a2 2 0 0 1 .58 1.6Z"/></svg> 1792 </div> 1793 <div class="flex--item wmn0 fl1 lh-lg"> 1794 <div class="flex--item fl1 lh-lg"> 1795 <div> 1796 <b><a href="/help/privileges/protect-questions">Highly active question</a></b>. Earn 10 reputation (not counting the <a href="https://meta.stackexchange.com/questions/141648/what-is-the-association-bonus-and-how-does-it-work">association bonus</a>) in order to answer this question. The reputation requirement helps protect this question from spam and non-answer activity. 1797 1798 </div> 1799 </div> 1800 </div> 1801 </div> 1802 </div> 1803 </aside> 1804 1805 1806 1807 <h2 class="bottom-notice" data-loc="1"> 1808 <div> 1809 Not the answer you're looking for? Browse other questions tagged <ul class='ml0 list-ls-none js-post-tag-list-wrapper d-inline'><li class='d-inline mr4 js-post-tag-list-item'><a href="/questions/tagged/python" class="post-tag" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class='d-inline mr4 js-post-tag-list-item'><a href="/questions/tagged/scipy" class="post-tag" title="show questions tagged 'scipy'" aria-label="show questions tagged 'scipy'" rel="tag" aria-labelledby="tag-scipy-tooltip-container">scipy</a></li><li class='d-inline mr4 js-post-tag-list-item'><a href="/questions/tagged/normal-distribution" class="post-tag" title="show questions tagged 'normal-distribution'" aria-label="show questions tagged 'normal-distribution'" rel="tag" aria-labelledby="tag-normal-distribution-tooltip-container">normal-distribution</a></li></ul> or <a href="/questions/ask">ask your own question</a>. </div> 1810 </h2> 1811 </div> 1812 </div> 1813 1814 1815 <div id="sidebar" class="show-votes" role="complementary" aria-label="sidebar"> 1816 1817 1818 1819 <div class="s-sidebarwidget s-sidebarwidget__yellow s-anchors s-anchors__grayscale mb16" data-tracker="cb=1"> 1820 <ul class="d-block p0 m0"> 1821 <li class="s-sidebarwidget--header s-sidebarwidget__small-bold-text d-flex fc-black-500 d:fc-black-600 bb bbw1"> 1822 The Overflow Blog 1823 </li> 1824 <li class="s-sidebarwidget--item d-flex px16"> 1825 <div class="flex--item1 fl-shrink0"> 1826 <svg aria-hidden="true" class="va-text-top svg-icon iconPencilSm" width="14" height="14" viewBox="0 0 14 14"><path fill="#F1B600" d="m2 10.12 6.37-6.43 1.88 1.88L3.88 12H2v-1.88Z"/><path fill="#E87C87" d="m11.1 1.71 1.13 1.12c.2.2.2.51 0 .71L11.1 4.7 9.21 2.86l1.17-1.15c.2-.2.51-.2.71 0Z"/></svg> </div> 1827 <div class="flex--item wmn0 ow-break-word"> 1828 <a href="https://stackoverflow.blog/2023/11/29/how-to-scale-a-business-ready-ai-platform-with-watsonx-q-and-a-with-ibm/" class="js-gps-track" data-ga="["community bulletin board","The Overflow Blog","https://stackoverflow.blog/2023/11/29/how-to-scale-a-business-ready-ai-platform-with-watsonx-q-and-a-with-ibm/",null,null]" data-gps-track="communitybulletin.click({ priority: 1, position: 0 })">How to scale a business-ready AI platform with watsonx: Q&A with IBM</a> 1829 <div class="fc-black-400 fs-italic">sponsored post</div> 1830 </div> 1831 </li> 1832 <li class="s-sidebarwidget--item d-flex px16"> 1833 <div class="flex--item1 fl-shrink0"> 1834 <svg aria-hidden="true" class="va-text-top svg-icon iconPencilSm" width="14" height="14" viewBox="0 0 14 14"><path fill="#F1B600" d="m2 10.12 6.37-6.43 1.88 1.88L3.88 12H2v-1.88Z"/><path fill="#E87C87" d="m11.1 1.71 1.13 1.12c.2.2.2.51 0 .71L11.1 4.7 9.21 2.86l1.17-1.15c.2-.2.51-.2.71 0Z"/></svg> </div> 1835 <div class="flex--item wmn0 ow-break-word"> 1836 <a href="https://stackoverflow.blog/2023/12/01/will-developers-return-to-hostile-offices/" class="js-gps-track" data-ga="["community bulletin board","The Overflow Blog","https://stackoverflow.blog/2023/12/01/will-developers-return-to-hostile-offices/",null,null]" data-gps-track="communitybulletin.click({ priority: 1, position: 1 })">Will developers return to hostile offices?</a> 1837 </div> 1838 </li> 1839 <li class="s-sidebarwidget--header s-sidebarwidget__small-bold-text d-flex fc-black-500 d:fc-black-600 bb bbw1"> 1840 Featured on Meta 1841 </li> 1842 <li class="s-sidebarwidget--item d-flex px16"> 1843 <div class="flex--item1 fl-shrink0"> 1844 <div class="favicon favicon-stackexchangemeta" title="Meta Stack Exchange"></div> </div> 1845 <div class="flex--item wmn0 ow-break-word"> 1846 <a href="https://meta.stackexchange.com/questions/394860/were-rolling-back-the-changes-to-the-acceptable-use-policy-aup" class="js-gps-track" data-ga="["community bulletin board","Featured on Meta","https://meta.stackexchange.com/questions/394860/were-rolling-back-the-changes-to-the-acceptable-use-policy-aup",null,null]" data-gps-track="communitybulletin.click({ priority: 3, position: 2 })">We're rolling back the changes to the Acceptable Use Policy (AUP)</a> 1847 </div> 1848 </li> 1849 <li class="s-sidebarwidget--item d-flex px16"> 1850 <div class="flex--item1 fl-shrink0"> 1851 <div class="favicon favicon-stackexchangemeta" title="Meta Stack Exchange"></div> </div> 1852 <div class="flex--item wmn0 ow-break-word"> 1853 <a href="https://meta.stackexchange.com/questions/395062/seeking-feedback-on-tag-colors-update" class="js-gps-track" data-ga="["community bulletin board","Featured on Meta","https://meta.stackexchange.com/questions/395062/seeking-feedback-on-tag-colors-update",null,null]" data-gps-track="communitybulletin.click({ priority: 3, position: 3 })">Seeking feedback on tag colors update</a> 1854 </div> 1855 </li> 1856 <li class="s-sidebarwidget--item d-flex px16"> 1857 <div class="flex--item1 fl-shrink0"> 1858 <div class="favicon favicon-stackoverflowmeta" title="Meta Stack Overflow"></div> </div> 1859 <div class="flex--item wmn0 ow-break-word"> 1860 <a href="https://meta.stackoverflow.com/questions/427199/collectives-updates-new-features-and-ways-to-get-started-with-discussions" class="js-gps-track" data-ga="["community bulletin board","Featured on Meta","https://meta.stackoverflow.com/questions/427199/collectives-updates-new-features-and-ways-to-get-started-with-discussions",null,null]" data-gps-track="communitybulletin.click({ priority: 6, position: 4 })">Collectives updates: new features and ways to get started with Discussions</a> 1861 </div> 1862 </li> 1863 <li class="s-sidebarwidget--item d-flex px16"> 1864 <div class="flex--item1 fl-shrink0"> 1865 <div class="favicon favicon-stackoverflowmeta" title="Meta Stack Overflow"></div> </div> 1866 <div class="flex--item wmn0 ow-break-word"> 1867 <a href="https://meta.stackoverflow.com/questions/427335/overflowai-alpha-invitation-emails-were-distributed-in-error-nov-28th" class="js-gps-track" data-ga="["community bulletin board","Featured on Meta","https://meta.stackoverflow.com/questions/427335/overflowai-alpha-invitation-emails-were-distributed-in-error-nov-28th",null,null]" data-gps-track="communitybulletin.click({ priority: 6, position: 5 })">OverflowAI Alpha invitation emails were distributed in error Nov 28th</a> 1868 </div> 1869 </li> 1870 <li class="s-sidebarwidget--item d-flex px16"> 1871 <div class="flex--item1 fl-shrink0"> 1872 <div class="favicon favicon-stackoverflowmeta" title="Meta Stack Overflow"></div> </div> 1873 <div class="flex--item wmn0 ow-break-word"> 1874 <a href="https://meta.stackoverflow.com/questions/421831/temporary-policy-generative-ai-e-g-chatgpt-is-banned" class="js-gps-track" data-ga="["community bulletin board","Featured on Meta","https://meta.stackoverflow.com/questions/421831/temporary-policy-generative-ai-e-g-chatgpt-is-banned",null,null]" data-gps-track="communitybulletin.click({ priority: 6, position: 6 })">Temporary policy: Generative AI (e.g., ChatGPT) is banned</a> 1875 </div> 1876 </li> 1877 </ul> 1878 </div> 1879 1880 1881 <div class="js-zone-container zone-container-sidebar"> 1882 <div id="dfp-tsb" class="everyonelovesstackoverflow everyoneloves__top-sidebar"></div> 1883 <div class="js-report-ad-button-container " style="width: 300px"></div> 1884 </div> 1885 <div class="js-zone-container zone-container-sidebar"> 1886 <div id="dfp-msb" class="everyonelovesstackoverflow everyoneloves__mid-sidebar"></div> 1887 <div class="js-report-ad-button-container " style="width: 300px"></div> 1888 </div> 1889 <div id="hireme"></div> <div class="module sidebar-linked"> 1890 <h4 id="h-linked">Linked</h4> 1891 <div class="linked" data-tracker="lq=1"> 1892 <div class="spacer js-gps-track" data-gps-track="linkedquestion.click({ source_post_id: 20626994, target_question_id: 29369776, position: 0 })"> 1893 <a href="/q/29369776" title="Question score (upvotes - downvotes)"> 1894 <div class="answer-votes default">9</div> 1895 </a> 1896 <a href="/questions/29369776/what-is-the-sci-numpython-equivalent-to-matlabs-norminv-normal-inverse-cumu?noredirect=1" class="question-hyperlink">What is the [Sci/Num]Python equivalent to Matlabs "norminv" (Normal inverse cumulative distribution function)</a> 1897 </div> 1898 <div class="spacer js-gps-track" data-gps-track="linkedquestion.click({ source_post_id: 20626994, target_question_id: 49115700, position: 1 })"> 1899 <a href="/q/49115700" title="Question score (upvotes - downvotes)"> 1900 <div class="answer-votes default">0</div> 1901 </a> 1902 <a href="/questions/49115700/python-equivalent-of-matlabs-qfuncinv?noredirect=1" class="question-hyperlink">Python equivalent of MATLAB's qfuncinv()</a> 1903 </div> 1904 <div class="spacer js-gps-track" data-gps-track="linkedquestion.click({ source_post_id: 20626994, target_question_id: 31648552, position: 2 })"> 1905 <a href="/q/31648552" title="Question score (upvotes - downvotes)"> 1906 <div class="answer-votes default">0</div> 1907 </a> 1908 <a href="/questions/31648552/how-can-i-get-the-value-in-normal-distribution-in-python?noredirect=1" class="question-hyperlink">How can I get the value in normal distribution in python</a> 1909 </div> 1910 <div class="spacer js-gps-track" data-gps-track="linkedquestion.click({ source_post_id: 20626994, target_question_id: 60699836, position: 3 })"> 1911 <a href="/q/60699836" title="Question score (upvotes - downvotes)"> 1912 <div class="answer-votes default">24</div> 1913 </a> 1914 <a href="/questions/60699836/how-to-use-norm-ppf?noredirect=1" class="question-hyperlink">How to use norm.ppf()?</a> 1915 </div> 1916 <div class="spacer js-gps-track" data-gps-track="linkedquestion.click({ source_post_id: 20626994, target_question_id: 31910485, position: 4 })"> 1917 <a href="/q/31910485" title="Question score (upvotes - downvotes)"> 1918 <div class="answer-votes answered-accepted default">9</div> 1919 </a> 1920 <a href="/questions/31910485/quantile-functions-in-python?noredirect=1" class="question-hyperlink">Quantile functions in Python</a> 1921 </div> 1922 <div class="spacer js-gps-track" data-gps-track="linkedquestion.click({ source_post_id: 20626994, target_question_id: 37794648, position: 5 })"> 1923 <a href="/q/37794648" title="Question score (upvotes - downvotes)"> 1924 <div class="answer-votes default">2</div> 1925 </a> 1926 <a href="/questions/37794648/equivalent-of-matlabs-gaminv-in-python?noredirect=1" class="question-hyperlink">equivalent of Matlab's gaminv in python</a> 1927 </div> 1928 <div class="spacer js-gps-track" data-gps-track="linkedquestion.click({ source_post_id: 20626994, target_question_id: 75820210, position: 6 })"> 1929 <a href="/q/75820210" title="Question score (upvotes - downvotes)"> 1930 <div class="answer-votes default">0</div> 1931 </a> 1932 <a href="/questions/75820210/call-scipy-from-matlab-using-python?noredirect=1" class="question-hyperlink">Call SciPy from MATLAB using Python</a> 1933 </div> 1934 <div class="spacer js-gps-track" data-gps-track="linkedquestion.click({ source_post_id: 20626994, target_question_id: 67955360, position: 7 })"> 1935 <a href="/q/67955360" title="Question score (upvotes - downvotes)"> 1936 <div class="answer-votes default">1</div> 1937 </a> 1938 <a href="/questions/67955360/inverse-of-cumulative-density-function-for-multivariate-normal-distribution?noredirect=1" class="question-hyperlink">Inverse of cumulative density function for Multivariate Normal Distribution</a> 1939 </div> 1940 <div class="spacer js-gps-track" data-gps-track="linkedquestion.click({ source_post_id: 20626994, target_question_id: 49172935, position: 8 })"> 1941 <a href="/q/49172935" title="Question score (upvotes - downvotes)"> 1942 <div class="answer-votes default">0</div> 1943 </a> 1944 <a href="/questions/49172935/typeerror-ufunc-ndtri-not-supported-for-the-input-types?noredirect=1" class="question-hyperlink">TypeError: ufunc 'ndtri' not supported for the input types</a> 1945 </div> 1946 <div class="spacer js-gps-track" data-gps-track="linkedquestion.click({ source_post_id: 20626994, target_question_id: 49045372, position: 9 })"> 1947 <a href="/q/49045372" title="Question score (upvotes - downvotes)"> 1948 <div class="answer-votes default">0</div> 1949 </a> 1950 <a href="/questions/49045372/how-to-correctly-calculate-the-median-of-a-probability-function?noredirect=1" class="question-hyperlink">How to correctly calculate the MEDIAN of a probability function?</a> 1951 </div> 1952 <div class="spacer more ml32 pl16 pt8"> 1953 <a href="/questions/linked/20626994">See more linked questions</a> 1954 </div> 1955 </div> 1956 </div> 1957 1958 1959 1960 1961 1962 <div class="module sidebar-related"> 1963 <h4 id="h-related">Related</h4> 1964 <div class="related js-gps-related-questions" data-tracker="rq=3"> 1965 <div class="spacer" data-question-id="19589191"> 1966 <a href="/q/19589191" title="Question score (upvotes - downvotes)" > 1967 <div class="answer-votes answered-accepted default">16</div> 1968 </a> 1969 <a href="/questions/19589191/the-reverse-inverse-of-the-normal-distribution-function-in-r" class="question-hyperlink">The reverse/inverse of the normal distribution function in R</a> 1970 </div> 1971 <div class="spacer" data-question-id="22264046"> 1972 <a href="/q/22264046" title="Question score (upvotes - downvotes)" > 1973 <div class="answer-votes answered-accepted default">5</div> 1974 </a> 1975 <a href="/questions/22264046/inverse-probability-density-function" class="question-hyperlink">Inverse probability density function</a> 1976 </div> 1977 <div class="spacer" data-question-id="37023041"> 1978 <a href="/q/37023041" title="Question score (upvotes - downvotes)" > 1979 <div class="answer-votes answered-accepted default">5</div> 1980 </a> 1981 <a href="/questions/37023041/how-to-calculate-the-inverse-of-the-log-normal-cumulative-distribution-function" class="question-hyperlink">How to calculate the inverse of the log normal cumulative distribution function in python?</a> 1982 </div> 1983 <div class="spacer" data-question-id="44983175"> 1984 <a href="/q/44983175" title="Question score (upvotes - downvotes)" > 1985 <div class="answer-votes default">2</div> 1986 </a> 1987 <a href="/questions/44983175/calculate-inverse-cdf-from-a-sample-of-data" class="question-hyperlink">Calculate inverse CDF from a sample of data</a> 1988 </div> 1989 <div class="spacer" data-question-id="46199199"> 1990 <a href="/q/46199199" title="Question score (upvotes - downvotes)" > 1991 <div class="answer-votes default">0</div> 1992 </a> 1993 <a href="/questions/46199199/how-to-calculate-normal-inverse-cumulative-distribution-function-efficiently-in" class="question-hyperlink">How to calculate normal inverse cumulative distribution function efficiently in Python</a> 1994 </div> 1995 <div class="spacer" data-question-id="47417986"> 1996 <a href="/q/47417986" title="Question score (upvotes - downvotes)" > 1997 <div class="answer-votes answered-accepted default">11</div> 1998 </a> 1999 <a href="/questions/47417986/using-scipy-gaussian-kernel-density-estimation-to-calculate-cdf-inverse" class="question-hyperlink">Using scipy gaussian kernel density estimation to calculate CDF inverse</a> 2000 </div> 2001 <div class="spacer" data-question-id="59012763"> 2002 <a href="/q/59012763" title="Question score (upvotes - downvotes)" > 2003 <div class="answer-votes default">4</div> 2004 </a> 2005 <a href="/questions/59012763/how-to-calculate-cumulative-normal-distribution-in-python" class="question-hyperlink">How to calculate cumulative normal distribution in python?</a> 2006 </div> 2007 <div class="spacer" data-question-id="60807221"> 2008 <a href="/q/60807221" title="Question score (upvotes - downvotes)" > 2009 <div class="answer-votes answered-accepted default">0</div> 2010 </a> 2011 <a href="/questions/60807221/why-not-the-inverse-of-inverse-function-of-a-standard-normal-distribution-calcul" class="question-hyperlink">Why not the inverse of inverse function of a standard normal distribution calculation at scipy.stats python identical?</a> 2012 </div> 2013 <div class="spacer" data-question-id="62899379"> 2014 <a href="/q/62899379" title="Question score (upvotes - downvotes)" > 2015 <div class="answer-votes answered-accepted default">0</div> 2016 </a> 2017 <a href="/questions/62899379/inverse-normal-random-number-generation-in-python" class="question-hyperlink">Inverse normal random number generation in python?</a> 2018 </div> 2019 <div class="spacer" data-question-id="70690215"> 2020 <a href="/q/70690215" title="Question score (upvotes - downvotes)" > 2021 <div class="answer-votes default">0</div> 2022 </a> 2023 <a href="/questions/70690215/python-reverse-probability-look-up-for-normal-distribution" class="question-hyperlink">python reverse probability look up for normal distribution</a> 2024 </div> 2025 </div> 2026 </div> 2027 <script type="text/javascript"> 2028 $(document).ready(function() { 2029 $(".js-gps-related-questions .spacer").click(function () { 2030 fireRelatedEvent($(this).index() + 1, $(this).data('question-id')); 2031 }); 2032 2033 function fireRelatedEvent(position, questionId) { 2034 StackExchange.using("gps", function() { 2035 StackExchange.gps.track('related_questions.click', 2036 { 2037 position: position, 2038 originQuestionId: 20626994, 2039 relatedQuestionId: +questionId, 2040 location: 'sidebar', 2041 source: 'Baseline' 2042 }); 2043 }); 2044 } 2045 }); 2046 </script> 2047 2048 2049 2050 <div id="hot-network-questions" class="module tex2jax_ignore"> 2051 <h4> 2052 <a href="https://stackexchange.com/questions?tab=hot" 2053 class="js-gps-track s-link s-link__inherit" 2054 data-gps-track="posts_hot_network.click({ item_type:1, location:11 })"> 2055 Hot Network Questions 2056 </a> 2057 </h4> 2058 <ul> 2059 <li > 2060 <div class="favicon favicon-unix" title="Unix & Linux Stack Exchange"></div><a href="https://unix.stackexchange.com/questions/762948/how-can-i-reformat-blocks-of-data-until-the-end-of-the-file-is-reached" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:106 }); posts_hot_network.click({ item_type:2, location:11 })"> 2061 How can I reformat blocks of data until the end of the file is reached? 2062 </a> 2063 2064 </li> 2065 <li > 2066 <div class="favicon favicon-politics" title="Politics Stack Exchange"></div><a href="https://politics.stackexchange.com/questions/82982/why-are-there-so-many-pro-palestinian-protestors-in-the-united-states" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:475 }); posts_hot_network.click({ item_type:2, location:11 })"> 2067 Why are there so many pro-Palestinian protestors in the United States? 2068 </a> 2069 2070 </li> 2071 <li > 2072 <div class="favicon favicon-codegolf" title="Code Golf Stack Exchange"></div><a href="https://codegolf.stackexchange.com/questions/267235/ungolf-the-wind" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:200 }); posts_hot_network.click({ item_type:2, location:11 })"> 2073 Ungolf the Wind 2074 </a> 2075 2076 </li> 2077 <li > 2078 <div class="favicon favicon-superuser" title="Super User"></div><a href="https://superuser.com/questions/1819045/high-memory-usage-after-copying-1-million-small-files-win10-x64" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:3 }); posts_hot_network.click({ item_type:2, location:11 })"> 2079 High memory usage after copying 1 million small files (Win10 x64) 2080 </a> 2081 2082 </li> 2083 <li > 2084 <div class="favicon favicon-rpg" title="Role-playing Games Stack Exchange"></div><a href="https://rpg.stackexchange.com/questions/209395/can-you-use-true-polymorph-and-an-intellect-devourer-to-potentially-learn-deep-s" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:122 }); posts_hot_network.click({ item_type:2, location:11 })"> 2085 Can you use True Polymorph and an Intellect Devourer to potentially learn Deep Speech and a secret? 2086 </a> 2087 2088 </li> 2089 <li class="dno js-hidden"> 2090 <div class="favicon favicon-codereview" title="Code Review Stack Exchange"></div><a href="https://codereview.stackexchange.com/questions/288197/binary-file-reader-and-writer" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:196 }); posts_hot_network.click({ item_type:2, location:11 })"> 2091 Binary file reader and writer 2092 </a> 2093 2094 </li> 2095 <li class="dno js-hidden"> 2096 <div class="favicon favicon-politics" title="Politics Stack Exchange"></div><a href="https://politics.stackexchange.com/questions/82989/are-there-any-wars-other-than-the-2023-israel-hamas-war-that-are-named-after-a-c" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:475 }); posts_hot_network.click({ item_type:2, location:11 })"> 2097 Are there any wars other than the 2023 Israel-Hamas War that are named after a country and a political party? 2098 </a> 2099 2100 </li> 2101 <li class="dno js-hidden"> 2102 <div class="favicon favicon-academia" title="Academia Stack Exchange"></div><a href="https://academia.stackexchange.com/questions/204513/supervisor-refuses-to-be-included-as-a-co-author-in-phd-student-papers" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:415 }); posts_hot_network.click({ item_type:2, location:11 })"> 2103 Supervisor refuses to be included as a co-author in PhD student papers? 2104 </a> 2105 2106 </li> 2107 <li class="dno js-hidden"> 2108 <div class="favicon favicon-tex" title="TeX - LaTeX Stack Exchange"></div><a href="https://tex.stackexchange.com/questions/702904/how-to-apply-drop-caps-in-verse-environment-in-memoir-class" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:85 }); posts_hot_network.click({ item_type:2, location:11 })"> 2109 How to apply drop caps in verse environment in memoir class? 2110 </a> 2111 2112 </li> 2113 <li class="dno js-hidden"> 2114 <div class="favicon favicon-opensource" title="Open Source Stack Exchange"></div><a href="https://opensource.stackexchange.com/questions/14461/distribute-the-code-as-closed-source-and-the-end-users-download-gplv3-dependenci" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:619 }); posts_hot_network.click({ item_type:2, location:11 })"> 2115 Distribute the code as closed source and the end users download GPLv3 dependencies separately 2116 </a> 2117 2118 </li> 2119 <li class="dno js-hidden"> 2120 <div class="favicon favicon-scifi" title="Science Fiction & Fantasy Stack Exchange"></div><a href="https://scifi.stackexchange.com/questions/281408/expert-required-to-identify-these-classic-80s-action-movies" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:186 }); posts_hot_network.click({ item_type:2, location:11 })"> 2121 Expert required to identify these classic 80's action movies 2122 </a> 2123 2124 </li> 2125 <li class="dno js-hidden"> 2126 <div class="favicon favicon-space" title="Space Exploration Stack Exchange"></div><a href="https://space.stackexchange.com/questions/64905/are-there-multiple-types-of-utc-time" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:508 }); posts_hot_network.click({ item_type:2, location:11 })"> 2127 Are there multiple types of UTC time? 2128 </a> 2129 2130 </li> 2131 <li class="dno js-hidden"> 2132 <div class="favicon favicon-gaming" title="Arqade"></div><a href="https://gaming.stackexchange.com/questions/405350/who-is-the-small-green-caterpillar-on-my-head" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:41 }); posts_hot_network.click({ item_type:2, location:11 })"> 2133 Who is the small green caterpillar on my head? 2134 </a> 2135 2136 </li> 2137 <li class="dno js-hidden"> 2138 <div class="favicon favicon-stackoverflow" title="Stack Overflow"></div><a href="https://stackoverflow.com/questions/77585408/why-do-trigonometric-functions-give-a-seemingly-incorrect-result" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:1 }); posts_hot_network.click({ item_type:2, location:11 })"> 2139 Why do trigonometric functions give a seemingly incorrect result? 2140 </a> 2141 2142 </li> 2143 <li class="dno js-hidden"> 2144 <div class="favicon favicon-japanese" title="Japanese Language Stack Exchange"></div><a href="https://japanese.stackexchange.com/questions/101904/does-the-kanji-%e4%b8%a1-have-the-reading-teru-%e3%81%a6%e3%82%8b" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:257 }); posts_hot_network.click({ item_type:2, location:11 })"> 2145 Does the kanji 両 have the reading teru (てる)? 2146 </a> 2147 2148 </li> 2149 <li class="dno js-hidden"> 2150 <div class="favicon favicon-langdev" title="Programming Language Design and Implementation Stack Exchange"></div><a href="https://langdev.stackexchange.com/questions/3271/why-are-volatile-objects-so-difficult-to-work-with-in-c" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:716 }); posts_hot_network.click({ item_type:2, location:11 })"> 2151 Why are volatile objects so difficult to work with in C++? 2152 </a> 2153 2154 </li> 2155 <li class="dno js-hidden"> 2156 <div class="favicon favicon-mathoverflow" title="MathOverflow"></div><a href="https://mathoverflow.net/questions/459586/what-are-some-toy-models-for-the-stable-homotopy-groups-of-spheres" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:504 }); posts_hot_network.click({ item_type:2, location:11 })"> 2157 What are some toy models for the stable homotopy groups of spheres? 2158 </a> 2159 2160 </li> 2161 <li class="dno js-hidden"> 2162 <div class="favicon favicon-music" title="Music: Practice & Theory Stack Exchange"></div><a href="https://music.stackexchange.com/questions/132863/how-can-i-dampen-the-sound-of-maracas" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:240 }); posts_hot_network.click({ item_type:2, location:11 })"> 2163 How can I dampen the sound of maracas? 2164 </a> 2165 2166 </li> 2167 <li class="dno js-hidden"> 2168 <div class="favicon favicon-puzzling" title="Puzzling Stack Exchange"></div><a href="https://puzzling.stackexchange.com/questions/123454/pse-advent-calendar-2023-day-2-wall-i-want-for-christmas" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:559 }); posts_hot_network.click({ item_type:2, location:11 })"> 2169 PSE Advent Calendar 2023 (Day 2): Wall I want for Christmas 2170 </a> 2171 2172 </li> 2173 <li class="dno js-hidden"> 2174 <div class="favicon favicon-rpg" title="Role-playing Games Stack Exchange"></div><a href="https://rpg.stackexchange.com/questions/209385/one-of-pcs-backstabbed-a-powerful-ally-how-do-i-punish-them-without-seeming-lik" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:122 }); posts_hot_network.click({ item_type:2, location:11 })"> 2175 One of PCs backstabbed a powerful ally. How do I punish them without seeming like singling them out? 2176 </a> 2177 2178 </li> 2179 <li class="dno js-hidden"> 2180 <div class="favicon favicon-workplace" title="The Workplace Stack Exchange"></div><a href="https://workplace.stackexchange.com/questions/194505/how-does-one-get-past-unlucky-work-history-streak" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:423 }); posts_hot_network.click({ item_type:2, location:11 })"> 2181 How does one get past unlucky work history streak? 2182 </a> 2183 2184 </li> 2185 <li class="dno js-hidden"> 2186 <div class="favicon favicon-tex" title="TeX - LaTeX Stack Exchange"></div><a href="https://tex.stackexchange.com/questions/702915/how-to-handle-urls-with-tex-special-charactors-in-a-footnote" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:85 }); posts_hot_network.click({ item_type:2, location:11 })"> 2187 How to handle URLs with TeX-special charactors in a footnote 2188 </a> 2189 2190 </li> 2191 <li class="dno js-hidden"> 2192 <div class="favicon favicon-crafts" title="Arts & Crafts Stack Exchange"></div><a href="https://crafts.stackexchange.com/questions/11981/is-there-an-easily-accessible-way-to-make-a-surface-very-bright-white" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:650 }); posts_hot_network.click({ item_type:2, location:11 })"> 2193 Is there an easily accessible way to make a surface very bright white? 2194 </a> 2195 2196 </li> 2197 <li class="dno js-hidden"> 2198 <div class="favicon favicon-academia" title="Academia Stack Exchange"></div><a href="https://academia.stackexchange.com/questions/204530/advisor-student-collaboration-or-lack-thereof-and-paper-authorship-in-mathemat" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:11, target_site:415 }); posts_hot_network.click({ item_type:2, location:11 })"> 2199 Advisor-student collaboration (or lack thereof) and paper authorship in mathematics: how does it work? 2200 </a> 2201 2202 </li> 2203 </ul> 2204 2205 <a href="#" 2206 class="show-more js-show-more js-gps-track" 2207 data-gps-track="posts_hot_network.click({ item_type:3, location:11 })"> 2208 more hot questions 2209 </a> 2210 </div> 2211 2212 <div id="feed-link" class="js-feed-link"> 2213 <a href="/feeds/question/20626994" title="Feed of this question and its answers"> 2214 <svg aria-hidden="true" class="fc-orange-400 svg-icon iconRss" width="18" height="18" viewBox="0 0 18 18"><path d="M3 1a2 2 0 0 0-2 2v12c0 1.1.9 2 2 2h12a2 2 0 0 0 2-2V3a2 2 0 0 0-2-2H3Zm0 1.5c6.9 0 12.5 5.6 12.5 12.5H13C13 9.55 8.45 5 3 5V2.5Zm0 5c4.08 0 7.5 3.41 7.5 7.5H8c0-2.72-2.28-5-5-5V7.5Zm0 5c1.36 0 2.5 1.14 2.5 2.5H3v-2.5Z"/></svg> 2215 Question feed 2216 </a> 2217 </div> 2218 <aside class="s-modal js-feed-link-modal" tabindex="-1" role="dialog" aria-labelledby="feed-modal-title" aria-describedby="feed-modal-description" aria-hidden="true"> 2219 <div class="s-modal--dialog js-modal-dialog wmx4" role="document" data-controller="se-draggable"> 2220 <h1 class="s-modal--header fw-bold js-first-tabbable" id="feed-modal-title" data-se-draggable-target="handle" tabindex="0"> 2221 Subscribe to RSS 2222 </h1> 2223 <div class="d-flex gs4 gsy fd-column"> 2224 <div class="flex--item"> 2225 <label class="d-block s-label c-default" for="feed-url"> 2226 Question feed 2227 <p class="s-description mt2" id="feed-modal-description">To subscribe to this RSS feed, copy and paste this URL into your RSS reader.</p> 2228 </label> 2229 </div> 2230 <div class="d-flex ps-relative"> 2231 <input class="s-input" type="text" name="feed-url" id="feed-url" readonly="readonly" value="https://stackoverflow.com/feeds/question/20626994" /> 2232 <svg aria-hidden="true" class="s-input-icon fc-orange-400 svg-icon iconRss" width="18" height="18" viewBox="0 0 18 18"><path d="M3 1a2 2 0 0 0-2 2v12c0 1.1.9 2 2 2h12a2 2 0 0 0 2-2V3a2 2 0 0 0-2-2H3Zm0 1.5c6.9 0 12.5 5.6 12.5 12.5H13C13 9.55 8.45 5 3 5V2.5Zm0 5c4.08 0 7.5 3.41 7.5 7.5H8c0-2.72-2.28-5-5-5V7.5Zm0 5c1.36 0 2.5 1.14 2.5 2.5H3v-2.5Z"/></svg> 2233 </div> 2234 </div> 2235 <a class="s-modal--close s-btn s-btn__muted js-modal-close js-last-tabbable" href="#" aria-label="Close"> 2236 <svg aria-hidden="true" class="svg-icon iconClearSm" width="14" height="14" viewBox="0 0 14 14"><path d="M12 3.41 10.59 2 7 5.59 3.41 2 2 3.41 5.59 7 2 10.59 3.41 12 7 8.41 10.59 12 12 10.59 8.41 7 12 3.41Z"/></svg> 2237 </a> 2238 </div> 2239 </aside> 2240 2241 </div> 2242 2243 </div> 2244 <script>StackExchange.ready(function(){$.get('/posts/20626994/ivc/44b3?prg=70cd82cb-cc0a-4f50-a471-7090a00d40da');});</script> 2245 <noscript><div><img src="/posts/20626994/ivc/44b3?prg=70cd82cb-cc0a-4f50-a471-7090a00d40da" class="dno" alt="" width="0" height="0"></div></noscript><div style="display:none" id="js-codeblock-lang">lang-py</div></div> 2246 2247 2248 2249 </div> 2250 </div> 2251 2252 2253 <script type="text/javascript"> 2254 var cam = cam || { opt: {} }; 2255 var clcGamLoaderOptions = cam || { opt: {} }; 2256 var opt = clcGamLoaderOptions.opt; 2257 2258 opt.omni = 'BwoLCMyGlY6Jjro8EAUYsvzqCSACKAI6InxweXRob258c2NpcHl8bm9ybWFsLWRpc3RyaWJ1dGlvbnxIAPIF59cxX0wgerk'; 2259 opt.refresh = !1; 2260 opt.refreshInterval = 90; 2261 opt.sf = !0; 2262 opt.hb = !1; 2263 opt.ll = !0; 2264 opt.tlb_position = 0; 2265 opt.personalization_consent = !1; 2266 opt.targeting_consent = !1; 2267 opt.performance_consent = !1; 2268 2269 opt.targeting = {Registered:['false'],'so-tag':['python','scipy','normal-distribution'],'tag-reportable':['python','scipy','normal-distribution'],NumberOfAnswers:['3']}; 2270 opt.adReportEnabled = !0; 2271 opt.adReportUrl = '/ads/report-ad'; 2272 opt.adReportText = 'Report this ad'; 2273 opt.adReportFileTypeErrorMessage = 'Please select a PNG or JPG file.'; 2274 opt.adReportFileSizeErrorMessage = 'The file must be under 2 MiB.'; 2275 opt.adReportErrorText = 'Error uploading ad report.'; 2276 opt.adReportThanksText = 'Thanks for your feedback. We’ll review this against our code of conduct and take action if necessary.'; 2277 opt.adReportLoginExpiredMessage = 'Your login session has expired, please login and try again.'; 2278 opt.adReportLoginErrorMessage = 'An error occurred when loading the report form - please try again'; 2279 opt.adReportModalClass = 'js-ad-report'; 2280 opt.perRequestGuid = '70cd82cb-cc0a-4f50-a471-7090a00d40da'; 2281 opt.responseHash = 'wFWdf7nbguQxGgmc6Xi6549SI7TAcptfAqv01Ih/NvA='; 2282 2283 2284 opt.targeting.TargetingConsent = ['False_Passive']; 2285 2286 const urlParams = new URLSearchParams(window.location.search); 2287 if (urlParams.has('dfptestads')) { 2288 const dfptestads = urlParams.get('dfptestads'); 2289 opt.targeting.DfpTestAds = dfptestads; 2290 } 2291 </script> 2292 <script>;(()=>{"use strict";var __webpack_modules__={23:(e,t,s)=>{s.d(t,{Z7:()=>d,eq:()=>a,kG:()=>r});const n=/^\/tags\//.test(location.pathname)||/^\/questions\/tagged\//.test(location.pathname)?"tag-pages":/^\/$/.test(location.pathname)||/^\/home/.test(location.pathname)?"home-page":"question-pages";let o=location.hostname;const i={slots:{lb:[[728,90]],mlb:[[728,90]],smlb:[[728,90]],bmlb:[[728,90]],sb:e=>"dfp-tsb"===e?[[300,250],[300,600]]:[[300,250]],"tag-sponsorship":[[730,135]],"mobile-below-question":[[320,50],[300,250]],msb:[[300,250],[300,600]],"talent-conversion-tracking":[[1,1]],"site-sponsorship":[[230,60]]},ids:{"dfp-tlb":"lb","dfp-mlb":"mlb","dfp-smlb":"smlb","dfp-bmlb":"bmlb","dfp-tsb":"sb","dfp-isb":"sb","dfp-tag":"tag-sponsorship","dfp-msb":"msb","dfp-sspon":"site-sponsorship","dfp-m-aq":"mobile-below-question"},idsToExcludeFromAdReports:["dfp-sspon"]};function r(){return Object.keys(i.ids)}function a(e){return i.idsToExcludeFromAdReports.indexOf(e)<0}function d(e){var t=e.split("_")[0];const s=i.ids[t];let r=i.slots[s];return"function"==typeof r&&(r=r(t)),{path:`/248424177/${o}/${s}/${n}`,sizes:r,zone:s}}},865:(e,t,s)=>{function n(e){return"string"==typeof e?document.getElementById(e):e}function o(e){return!!(e=n(e))&&"none"===getComputedStyle(e).display}function i(e){return!o(e)}function r(e){return!!e}function a(e){return/^\s*$/.test(n(e).innerHTML)}function d(e){const{style:t}=e;t.height=t.maxHeight=t.minHeight="auto",t.display="none"}function l(e){const{style:t}=e;t.height=t.maxHeight=t.minHeight="auto",t.display="none",[].forEach.call(e.children,l)}function c(e){const{style:t}=e;t.height=t.maxHeight=t.minHeight="auto",t.removeProperty("display")}function g(e){const t=document.createElement("script");t.src=e,document.body.appendChild(t)}function p(e){return s=e,(t=[]).push=function(e){return s(),delete this.push,this.push(e)},t;var t,s}function h(e){let t="function"==typeof HTMLTemplateElement;var s=document.createElement(t?"template":"div");return e=e.trim(),s.innerHTML=e,t?s.content.firstChild:s.firstChild}s.d(t,{$Z:()=>c,Bv:()=>h,Gx:()=>g,Nj:()=>n,QZ:()=>p,cf:()=>d,pn:()=>i,wo:()=>l,xb:()=>a,xj:()=>o,yb:()=>r})},763:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{t:()=>AdReports});var _common_helper__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__(865),_console__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__(276),_ad_units__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(23);class AdReports{constructor(e,t){if(this.googletag=e,this.cam=t,this.allowedFileTypes=["image/png","image/jpg","image/jpeg"],this.ignoreValidation=!1,_console__WEBPACK_IMPORTED_MODULE_1__.cM("Ad reporting init"),this.cam=t,this.callOnButtonClick=e=>this.onButtonClick(e),this.googletag.pubads().addEventListener("slotRenderEnded",e=>this.handleSlotRendered(e)),Array.isArray(t.slotsRenderedEvents)){_console__WEBPACK_IMPORTED_MODULE_1__.cM("Adding report button to "+t.slotsRenderedEvents.length+" events that have transpired");for(var s=0;s<t.slotsRenderedEvents.length;s++)this.handleSlotRendered(t.slotsRenderedEvents[s])}}handleSlotRendered(e){if(e&&e.slot&&!e.isEmpty&&(e.creativeId||e.lineItemId||!e.isEmpty)){var t=e.slot.getSlotElementId();if(t){var s=document.getElementById(t);if(s)if((0,_ad_units__WEBPACK_IMPORTED_MODULE_0__.eq)(t)){var n=s?.closest(".js-zone-container")?.querySelector(".js-report-ad-button-container");n.innerHTML="",n.append(this.createButton(e)),n.style.height="24px",_console__WEBPACK_IMPORTED_MODULE_1__.cM("Added report button to the bottom of "+t)}else _console__WEBPACK_IMPORTED_MODULE_1__.cM("Not adding report button to the bottom of "+t+": shouldHaveReportButton = false");else _console__WEBPACK_IMPORTED_MODULE_1__.cM("Not adding report button to the bottom of "+t+": resolved invalid adUnit element")}else _console__WEBPACK_IMPORTED_MODULE_1__.cM("Not adding report button to the bottom of element: invalid adUnitElementId")}else _console__WEBPACK_IMPORTED_MODULE_1__.cM("Not adding report button to the bottom of element: invalid SlotRenderEndedEvent")}async onButtonClick(e){e.preventDefault();let t=e.target;const s=t.dataset.modalUrl,n=t.dataset.googleEventData;return await this.loadModal(s,t,n),!1}createButton(e){let t=document.createElement("button");var s=JSON.stringify(e);return t.dataset.googleEventData=s,t.dataset.modalUrl=this.cam.opt.adReportUrl,t.dataset.adUnit=e.slot.getSlotElementId(),t.classList.add("js-report-ad","s-btn","s-btn__link","fs-fine","mt2","float-right"),t.append(document.createTextNode(this.cam.opt.adReportText)),t.removeEventListener("click",this.callOnButtonClick),t.addEventListener("click",this.callOnButtonClick),t}async loadModal(url,$link,googleEventData){try{await window.StackExchange.helpers.loadModal(url,{returnElements:window.$($link)}),this.initForm(googleEventData)}catch(e){var message="",response=e.responseText?eval(`(${e.responseText})`):null;message=response&&response.isLoggedOut?this.cam.opt.adReportLoginExpiredMessage:this.cam.opt.adReportLoginErrorMessage,window.StackExchange.helpers.showToast(message,{type:"danger"})}}removeModal(){window.StackExchange.helpers.closePopups(document.querySelectorAll("."+this.cam.opt.adReportModalClass),"dismiss")}initForm(e,t=!1){this.ignoreValidation=t,this.$form=document.querySelector(".js-ad-report-form"),this.$googleEventData=this.$form.querySelector(".js-json-data"),this.$adReportReasons=this.$form.querySelectorAll(".js-ad-report-reason"),this.$adReportReasonOther=this.$form.querySelector(".js-ad-report-reason-other"),this.$fileUploaderInput=this.$form.querySelector(".js-file-uploader-input"),this.$imageUploader=this.$form.querySelector(".js-image-uploader"),this.$clearImageUpload=this.$form.querySelector(".js-clear-image-upload"),this.$imageUploaderText=this.$form.querySelector(".js-image-uploader-text"),this.$imageUploaderPreview=this.$form.querySelector(".js-image-uploader-preview"),this.$fileErrorMessage=this.$form.querySelector(".js-file-error");const s=this.$form.querySelector(".js-drag-drop-enabled"),n=this.$form.querySelector(".js-drag-drop-disabled");this.$googleEventData.value=e,this.$adReportReasons.forEach((e,t)=>e.addEventListener("change",e=>{this.$adReportReasonOther.classList.toggle("d-none","3"!==e.target.value)})),this.$fileUploaderInput.addEventListener("change",()=>{this.validateFileInput()&&this.updateImagePreview(this.$fileUploaderInput.files)}),this.$clearImageUpload.addEventListener("click",e=>{e.preventDefault(),this.clearImageUpload()});try{this.$fileUploaderInput[0].value="",this.$imageUploader.addEventListener("dragenter dragover dragleave drop",this.preventDefaults),this.$imageUploader.addEventListener("dragenter dragover",this.handleDragStart),this.$imageUploader.addEventListener("dragleave drop",this.handleDragEnd),this.$imageUploader.addEventListener("drop",this.handleDrop)}catch(e){s.classList.add("d-none"),n.classList.remove("d-none")}this.$form.removeEventListener("",this.handleDragEnd),this.$form.addEventListener("submit",async e=>(e.preventDefault(),this.submitForm(),!1))}clearImageUpload(){this.$fileUploaderInput.value="",this.$imageUploaderPreview.setAttribute("src",""),this.$imageUploaderPreview.classList.add("d-none"),this.$clearImageUpload.classList.add("d-none"),this.$imageUploaderText.classList.remove("d-none"),this.$imageUploader.classList.add("p16","ba","bas-dashed","bc-black-100")}preventDefaults(e){e.preventDefault(),e.stopPropagation()}handleDragStart(e){this.$imageUploader.classList.remove("bas-dashed"),this.$imageUploader.classList.add("bas-solid","bc-black-100")}handleDragEnd(e){this.$imageUploader.classList.remove("bas-solid","bc-black-100"),this.$imageUploader.classList.add("bas-dashed")}handleDrop(e){var t=e.originalEvent.dataTransfer.files;FileReader&&t&&1===t.length&&(this.$fileUploaderInput.files=t,this.validateFileInput()&&this.updateImagePreview(t))}setError(e){this.$fileErrorMessage.parentElement.classList.toggle("has-error",e)}updateImagePreview(e){this.$imageUploader.classList.remove("p16","ba","bas-dashed","bc-black-100"),this.$clearImageUpload.classList.remove("d-none"),this.$imageUploaderText.classList.add("d-none");var t=new FileReader;t.onload=e=>{null!=e.target&&(this.$imageUploaderPreview.setAttribute("src",e.target.result),this.$imageUploaderPreview.classList.remove("d-none"))},t.readAsDataURL(e[0])}validateFileInput(){if(this.ignoreValidation)return!0;const e=this.cam.opt.adReportFileTypeErrorMessage,t=this.cam.opt.adReportFileSizeErrorMessage;if(null==this.$fileUploaderInput.files)return!1;var s=this.$fileUploaderInput.files[0];return null==s?(this.setError(!0),!1):this.allowedFileTypes.indexOf(s.type)<0?(this.$fileErrorMessage.textContent=e,this.$fileErrorMessage.classList.remove("d-none"),this.setError(!0),!1):s.size>2097152?(this.$fileErrorMessage.textContent=t,this.$fileErrorMessage.classList.remove("d-none"),this.setError(!0),!1):(this.$fileErrorMessage.classList.add("d-none"),this.setError(!1),!0)}async gatherDiagnosticInfo(){return{BrowserVersion:await this.getBrowserVersion()}}getElementSource(e){return e.outerHTML}getNestedIFrameElement(e){var t=e.querySelector("iframe");return t.contentDocument?t.contentDocument.documentElement:t.contentWindow.document.documentElement}async getBrowserVersion(){return await navigator.userAgentData.getHighEntropyValues(["fullVersionList"]).then(e=>JSON.stringify(e.fullVersionList))}async submitForm(){if(!this.validateFileInput())return!1;this.$form.querySelector("[type=submit]").setAttribute("disabled","true");var e=JSON.parse(this.$googleEventData.value||"{}");e.Reason=parseInt(this.$form.querySelector(".js-ad-report-reason:checked").value,10),e.Description=this.$adReportReasonOther.value,this.$googleEventData.value=JSON.stringify(e);var t=new FormData(this.$form);if("1"===t.get("shareDiagnosticInfo")){var s=await this.gatherDiagnosticInfo();Object.keys(s).forEach(e=>t.append(e,s[e]))}try{const e=await window.fetch(this.$form.getAttribute("action"),{method:this.$form.getAttribute("method"),body:t,cache:"no-cache"}),s=e.headers.get("content-type")||"",o=await e.text();if(!e.ok)throw new Error("response not valid");if(0===s.indexOf("text/html")){var n=(0,_common_helper__WEBPACK_IMPORTED_MODULE_2__.Bv)(o);const e=n?n.querySelector(".js-modal-content"):null;if(_console__WEBPACK_IMPORTED_MODULE_1__.cM("$popupContent"),_console__WEBPACK_IMPORTED_MODULE_1__.cM(e),!e)throw new Error(`Could not find .js-modal-content in response from ${this.$form.getAttribute("action")}`);document.querySelector(".js-modal-content").replaceWith(e)}else window.StackExchange.helpers.showToast(this.cam.opt.adReportThanksText,{type:"success"}),this.removeModal()}catch(e){window.StackExchange.helpers.showToast(this.cam.opt.adReportErrorText,{type:"danger"})}finally{let e=this.$form.querySelector("[type=submit]");e&&e.removeAttribute("disabled")}}}},276:(e,t,s)=>{function n(...e){}function o(...e){}s.d(t,{cM:()=>n,vU:()=>o})}},__webpack_module_cache__={};function __webpack_require__(e){var t=__webpack_module_cache__[e];if(void 0!==t)return t.exports;var s=__webpack_module_cache__[e]={exports:{}};return __webpack_modules__[e](s,s.exports,__webpack_require__),s.exports}__webpack_require__.d=(e,t)=>{for(var s in t)__webpack_require__.o(t,s)&&!__webpack_require__.o(e,s)&&Object.defineProperty(e,s,{enumerable:!0,get:t[s]})},__webpack_require__.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var __webpack_exports__={};(()=>{var e=__webpack_require__(276),t=(e=>(e[e.Above=0]="Above",e[e.Below=1]="Below",e))(t||{});const s=Object.assign({},{"lib":"https://cdn.sstatic.net/clc/js/bundles/gam_loader_script/gam_loader_script.bundle.741.844f6c3cc28ce2d65ae9.min.js","style":null,"u":null,"wa":true,"kt":2000,"tto":true,"h":"clc.stackoverflow.com","allowed":"^(((talent\\.)?stackoverflow)|(blog\\.codinghorror)|(.*\\.googlesyndication)|(serverfault|askubuntu)|([^\\.]+\\.stackexchange))\\.com$","wv":true,"al":false,"abd":true,"cpa_liid":[5882654614],"cpa_cid":[138377597667],"dp":false,"tgt_to":1000,"tgt_u":"https://clc.stackoverflow.com/get-user-acct-tgt","tgt_e":false,"tgt_p":0});var n=__webpack_require__(23),o=__webpack_require__(865),i=__webpack_require__(763);class r{constructor(t,s){this.googletag=t,this.interval=s,e.cM("Ad refresh init. interval: "+s),this.googletag.pubads().addEventListener("impressionViewable",e=>this.onImpressionViewable(e)),e.cM("done enabling ad refresh")}onImpressionViewable(t){var s=t.slot;e.cM("ad refresh - slot "+s.getSlotElementId()+" is viewable, initializing refresh"),this.scheduleRefresh(s)}scheduleRefresh(e){setTimeout(()=>this.refreshAdSlot(e),1e3*this.interval)}static refreshMyAd(t,s){let n=t.pubads().getSlots().find(e=>e.getSlotElementId()===s);n&&(e.cM("refreshMyAd - refreshing ad slot "+s),t.pubads().refresh([n]))}refreshAdSlot(t){var s=t.getSlotElementId();this.isElementVisibleInBrowser(s)?(e.cM("refreshing ad slot "+s),googletag.pubads().refresh([t])):(e.cM("refresh skipped this time; ad slot not viewable:"+s),this.scheduleRefresh(t))}isElementVisibleInBrowser(e){var t=document.getElementById(e);if(null!==t){var s=t.getBoundingClientRect();if(s.top>=0&&s.left>=0&&s.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&s.right<=(window.innerWidth||document.documentElement.clientWidth))return!0}return!1}}var a=(e=>(e.Off="Off",e.PreSurvey="PreSurvey",e.Collect="Collect",e.PostSurvey="PostSurvey",e))(a||{});class d{constructor(e,t){this.lineItemImpressions=[],this.surveysIdsCompleted=[],this.lineItemImpressions=e,this.surveysIdsCompleted=t}addImpression(e,t){let s={brandId:e,lineItemId:t,timestamp:new Date};this.lineItemImpressions.push(s)}addBrandSurveyCompleted(e){-1===this.surveysIdsCompleted.indexOf(e)&&this.surveysIdsCompleted.push(e)}getTotalBrandImpressions(){let e=new Map;for(let t of this.lineItemImpressions)if(e.has(t.brandId)){let s=e.get(t.brandId);e.set(t.brandId,s+1)}else e.set(t.brandId,1);return e}getBrandLineItemImpressions(e){let t={};for(let s of this.lineItemImpressions)if(s.brandId==e)if(void 0!==t[s.lineItemId]){let e=t[s.lineItemId];t[s.lineItemId]=e+1}else t[s.lineItemId]=1;return t}}class l{constructor(){this.surveyEngagementLocalStorageKey="clc-survey-engagement"}getBrandSurveyEngagement(){let e=localStorage.getItem(this.surveyEngagementLocalStorageKey);if(null===e)return new d([],[]);let t=JSON.parse(e);return new d(t.lineItemImpressions,t.surveysIdsCompleted)}saveBrandSurveyEngagement(e){let t=JSON.stringify(e);localStorage.setItem(this.surveyEngagementLocalStorageKey,t)}}class c{constructor(){this.surveyRepository=new l}getBrandSurveyEngagement(){return this.surveyRepository.getBrandSurveyEngagement()}recordImpression(e,t){let s=this.getBrandSurveyEngagement();s.addImpression(e,t),this.surveyRepository.saveBrandSurveyEngagement(s)}recordBrandSurveyCompleted(e){let t=this.getBrandSurveyEngagement();t.addBrandSurveyCompleted(e),this.surveyRepository.saveBrandSurveyEngagement(t)}}class g{constructor(t,s){this.googletag=t,this.brandSettings=s,this.brandSlotMap=new Map,this.brandSurveyEngagementService=new c,e.cM("Brand Survey init: "+JSON.stringify(s)),void 0!==s?(this.googletag.pubads().addEventListener("slotRenderEnded",e=>this.handleSlotRendered(e)),this.googletag.pubads().addEventListener("impressionViewable",e=>this.onImpressionViewable(e)),e.cM("done enabling Brand Survey")):e.cM("Brand Survey init: brandSettings is undefined, not initializing")}handleSlotRendered(t){e.cM("Brand Survey - slot rendered - slot:"+JSON.stringify(t.slot.getSlotElementId())+" lineItem: "+t.lineItemId);let s=this.findItemWithId(t.lineItemId);if(null===s||s.mode!==a.Collect)this.brandSlotMap.delete(t.slot.getSlotElementId());else{let e={brandId:s.brandId,lineItemId:t.lineItemId};this.brandSlotMap.set(t.slot.getSlotElementId(),e)}}onImpressionViewable(t){let s=t.slot;if(e.cM("ad - Brand Survey - impression viewable. Details: "+JSON.stringify(s.getSlotElementId())),e.cM("ad - Brand Survey - slot "+s.getSlotElementId()+" is viewable"),this.brandSlotMap.has(s.getSlotElementId())){let t=this.brandSlotMap.get(s.getSlotElementId());e.cM("Brand Survey - brand "+t.brandId+" is viewable"),this.recordImpression(this.brandSlotMap.get(s.getSlotElementId()))}}recordImpression(t){e.cM("ad - Brand Survey - recording impression for brand "+t.brandId),this.brandSurveyEngagementService.recordImpression(t.brandId,t.lineItemId)}findItemWithId(t){return e.cM("brand settings: "+JSON.stringify(this.brandSettings)),this.brandSettings.find(e=>e.lineItemIds.includes(t))||null}}const p="response-brand-survey-submit|",h="request-brand-survey-metadata|",m="record-metric-on-server|",u="request-dsp-tags",f="response-dsp-tags|";class v{static refreshAdIfBrandSurveyIsDuplicated(e,t,s){this.alreadyCompletedThisBrandSurvey(t)&&r.refreshMyAd(e,s)}static alreadyCompletedThisBrandSurvey(e){return(new c).getBrandSurveyEngagement().surveysIdsCompleted.includes(e)}}window.cam=new class{constructor(t=null){if(this.gptImported=!1,this.slotsRenderedEvents=[],this.collapsed={},e.cM("constructor"),this.clc_options=s,window.clcGamLoaderOptions)Object.assign(this,window.clcGamLoaderOptions);else if(void 0===this.opt){let e=window.opt;e&&(this.opt=e)}}init(){if(e.cM("init"),void 0===this.opt)throw new Error("opt not set, required by GAM Loader");e.cM("init brand survey service"),this.getUserAccountTargetingPromise=this.getUserAccountTargeting(),e.cM("setup message handler"),window.addEventListener("message",e=>{this.onmessage(e)})}handleSlotRenderedNoAdReport(){if(googletag.pubads().addEventListener("slotRenderEnded",e=>this.applyExtraMarginBottom(e)),Array.isArray(this.slotsRenderedEvents))for(var e=0;e<this.slotsRenderedEvents.length;e++)this.applyExtraMarginBottom(this.slotsRenderedEvents[e])}onmessage(t){let s="omni";if(t.data&&("string"==typeof t.data||t.data instanceof String))if(0===t.data.indexOf("get-omni-")){e.cM("Recevied get-omni message, sending back omni");var n=t.source,i=this.opt.omni,r="string"==typeof i?i:"";n.postMessage([s,r,this.opt.perRequestGuid].join("|"),"*")}else if(0===t.data.indexOf("collapse-")){e.cM("Recevied collapse message, collapse ad iframe"),e.cM(t);for(var a=t.source.window,d=document.getElementsByTagName("IFRAME"),l=0;l<d.length;l++){var g=d[l];if(g.contentWindow==a)return void(0,o.wo)(g.parentElement.parentElement.parentElement)}}else if(0===t.data.indexOf("resize|")){e.cM("Recevied resize message, resize ad iframe"),e.cM(t);let s=this._getFrameByEvent(t),n=t.data.indexOf("|")+1,o=t.data.slice(n),i=parseFloat(o)+.5;e.cM("New iframe height "+i),s.height=i.toString(),s.parentElement.style.height=i.toString()+"px"}else if(0===t.data.indexOf("getmarkup|")){let s=t.data.indexOf("|")+1,n=t.data.slice(s);e.cM("Recevied get markup message: "+n);let o=this._getFrameByEvent(t).closest(".everyonelovesstackoverflow");const i=document.createElement("script");i.dataset.adZoneId=o.id,i.src=n,document.body.appendChild(i)}else if(0===t.data.indexOf("window-location|")){let s=t.data.indexOf("|")+1,n=t.data.slice(s);e.cM("Recevied window location message: "+n),n.startsWith("/")||(n="/"+n),window.open(window.location.protocol+"//"+window.location.host+n,"_blank")}else if(0===t.data.indexOf("request-brand-survey-submit|")){let s=t.data.split("|"),n=s[1],o=s[2],i=s[3],r=JSON.parse(i);e.cM(n),e.cM(o),e.cM(i),e.cM("Received brand survey "+n+" response message: "+o);var b=new FormData;for(var _ in r)b.append(_,r[_]);let a=this._getFrameByEvent(t);if(v.alreadyCompletedThisBrandSurvey(+n))return e.cM("Already completed this brand survey. Not submitting duplicate to server."),void a.contentWindow.postMessage("response-brand-survey-submit-duplicate|","*");e.cM("Send the brand survey to the server"),fetch(o,{method:"POST",body:b}).then(e=>e.json()).then(e=>a.contentWindow.postMessage(p,"*")).catch(e=>a.contentWindow.postMessage(p,"*"))}else if(0===t.data.indexOf("brand-survey-completed-store|")){let s=t.data.split("|"),n=(s[1],s[2]);if(e.cM("Received brand survey completed store message for survey ID "+n),v.alreadyCompletedThisBrandSurvey(+n))return void e.cM("Already completed this brand survey. Not recording duplicate locally.");e.cM("Record brand survey completion locally"),(new c).recordBrandSurveyCompleted(+n)}else if(0===t.data.indexOf(h)){let s=t.data.split("|"),n=s[1],o=s[2];e.cM("Received message: request-brand-survey-metadata| with Brand Survey ID "+o);let i=(new c).getBrandSurveyEngagement().getBrandLineItemImpressions(+n),r=JSON.stringify(i),a=this._getFrameByEvent(t);e.cM("sending impression data: "+r),a.contentWindow.postMessage("response-brand-survey-metadata|"+this.opt.responseHash+"|"+this.opt.perRequestGuid+"|"+r,"*")}else if(0===t.data.indexOf("refresh-if-duplicate-brand-survey|")){let e=t.data.split("|")[1],s=this.getSlotElementIdByEvent(t);v.refreshAdIfBrandSurveyIsDuplicated(googletag,+e,s)}else if(0===t.data.indexOf(m)){e.cM("Received message: record-metric-on-server| with args: "+t.data);let s=t.data.split("|"),n=s[1],o=s[2],i=s[3],r=s[4],a=new FormData;a.append("brandSurveyId",i.toString()),a.append("responseHash",this.opt.responseHash),a.append("perRequestGuid",this.opt.perRequestGuid),a.append("questionNumber",n.toString()),a.append("metricType",r.toString()),fetch(o,{method:"POST",body:a}).then(e=>e.ok).catch(t=>{e.cM("SendMetricToServer: Error sending metric to server: "+t)})}else if(0===t.data.indexOf(u)){e.cM("Received message: request-dsp-tags with args: "+t.data);let s=this._getFrameByEvent(t);if(!this.opt.targeting["so-tag"])return void s.contentWindow.postMessage(f,"*");const n=this.opt.targeting["so-tag"].join(",");e.cM("sending targeting tags: "+n),s.contentWindow.postMessage(f+n,"*")}else e.cM("Received unhandled message")}getSlotElementIdByEvent(e){let t=this._getFrameByEvent(e).parentElement?.parentElement?.id;return t||""}_getFrameByEvent(e){return Array.from(document.getElementsByTagName("iframe")).filter(t=>t.contentWindow===e.source)[0]}classifyZoneIds(e){const t=e.map(o.Nj).filter(o.yb);return{eligible:t.filter(o.xb).filter(o.pn),ineligible:t.filter(o.xj)}}applyExtraMarginBottom(t){if(t&&t.slot&&!t.isEmpty&&(t.creativeId||t.lineItemId||!t.isEmpty)){var s=t.slot.getSlotElementId();if(s){var o=document.getElementById(s);if(o)if((0,n.eq)(s)){var i=o?.closest(".js-zone-container");i.style.marginBottom="24px",e.cM("Applied extra margin to the bottom of "+s)}else e.cM("Not applying extra margin to the bottom of "+s+": shouldHaveReportButton = false");else e.cM("Not applying extra margin to the bottom of "+s+": resolved invalid adUnit element")}else e.cM("Not applying extra margin to the bottom of element: invalid adUnitElementId")}else e.cM("Not applying extra margin to the bottom of element: invalid SlotRenderEndedEvent")}async load(s=(0,n.kG)()){const a=this.opt.tlb_position===t.Above?["dfp-mlb","dfp-smlb"]:["dfp-mlb","dfp-smlb","dfp-tlb"];if(!this.isGptReady())return e.cM("Initializing..."),this.initGpt(),void googletag.cmd.push(()=>this.load(s));this.opt.adReportEnabled?(e.cM("Ad reporting enabled"),this.adReports=new i.t(googletag,this)):(e.cM("Ad reporting not enabled"),this.handleSlotRenderedNoAdReport()),this.opt.refresh?(e.cM("Ad refresh enabled"),this.adRefresh=new r(googletag,this.opt.refreshInterval)):e.cM("Ad refresh not enabled"),this.opt.brandSurveyEnabled&&(e.cM("Brand Survey enabled"),this.brandSurvey=new g(googletag,this.opt.brandSurveySettings)),e.cM("Attempting to load ads into ids: ",s);const{eligible:d,ineligible:l}=this.classifyZoneIds(s);if(this.initDebugPanel(googletag,d.concat(l)),d.forEach(e=>(0,o.cf)(e)),l.forEach(o.wo),0===d.length)return void e.cM("Found no ad ids on page");e.cM("Eligible ids:",d),this.opt.abd&&this.appendAdblockDetector();var c=googletag.pubads().getSlots();if(c){var p=c.filter(e=>s.indexOf(e.getSlotElementId())>=0);googletag.destroySlots(p)}this.opt.sf&&(googletag.pubads().setForceSafeFrame(!0),googletag.pubads().setSafeFrameConfig({allowOverlayExpansion:!0,allowPushExpansion:!0,sandbox:!0})),e.cM("Targeting consent: Checking...");let h=!1,m=!1;void 0!==this.opt.targeting_consent&&(m=!0,e.cM("Targeting consent: Parameter set"),e.cM("Targeting consent: Consent given? ",this.opt.targeting_consent),h=this.opt.targeting_consent),void 0!==this.opt.personalization_consent&&(e.cM("Personalization consent: Parameter set"),e.cM("Personalization consent: Consent given? ",this.opt.personalization_consent),h=h&&this.opt.personalization_consent),h=h&&m,this.setPrivacySettings(h),this.opt.ll||googletag.pubads().enableSingleRequest(),cam.sreEvent||(googletag.pubads().addEventListener("slotRenderEnded",e=>this.onSlotRendered(e)),cam.sreEvent=!0),await this.setTargeting();var u=d.filter(e=>!this.opt.ll||a.indexOf(e.id)<0),f=d.filter(e=>!!this.opt.ll&&a.indexOf(e.id)>=0);e.cM("Up front ids:",u),e.cM("Lazy loaded ids:",f),u.forEach(t=>{e.cM(`Defining ad for element ${t.id}`),this.defineSlot(t.id,googletag),t.setAttribute("data-dfp-zone","true")}),googletag.enableServices(),u.forEach(t=>{e.cM(`Displaying ad for element ${t.id}`),googletag.cmd.push(()=>googletag.display(t.id))}),this.opt.ll&&(e.cM("Enabling lazy loading for GAM"),googletag.pubads().enableLazyLoad({fetchMarginPercent:0,renderMarginPercent:0}),e.cM("Setting up lazy loaded ad units"),f.forEach(t=>{e.cM(`Lazy loading - Defining Slot ${t.id}`),this.defineSlot(t.id,googletag)}),f.forEach(t=>{e.cM(`Lazy loading - Displaying ad for element ${t.id}`),googletag.cmd.push(()=>googletag.display(t.id))}))}setPrivacySettings(e){e?googletag.pubads().setPrivacySettings({limitedAds:!1,nonPersonalizedAds:!1}):googletag.pubads().setPrivacySettings({limitedAds:!0,nonPersonalizedAds:!0})}async setTargeting(){if(!googletag)throw new Error("googletag not defined");let t=this.opt.targeting;if(!t)throw new Error("Targeting not defined (is "+typeof t+")");Object.keys(t).forEach(s=>{e.cM(`-> targeting - ${s}: ${t[s]}`),googletag.pubads().setTargeting(s,t[s])});let s=!1;if(void 0!==this.opt.targeting_consent&&(s=this.opt.targeting_consent),s){let t=(new c).getBrandSurveyEngagement();if(t.getTotalBrandImpressions().forEach((t,s)=>{e.cM(`-> targeting - BrandImpressions: ${s}: ${t}`),googletag.pubads().setTargeting("brand_"+s.toString()+"_impressions",t.toString())}),t.surveysIdsCompleted.forEach(t=>{e.cM(`-> targeting - SurveysTaken: ${t}`),googletag.pubads().setTargeting("survey_"+t+"_taken","true")}),this.clc_options.tgt_e&&this.getUserAccountTargetingPromise){let t=await this.getUserAccountTargetingPromise;t&&t.tgt_acct?(e.cM("-> targeting - User Account: "+t.tgt_acct),googletag.pubads().setTargeting("user-acct",t.tgt_acct)):e.cM("-> targeting - User Account: Not Found")}}}appendAdblockDetector(){const e=document.createElement("div");e.className="adsbox",e.id="clc-abd",e.style.position="absolute",e.style.pointerEvents="none",e.innerHTML=" ",document.body.appendChild(e)}onSlotRendered(s){try{const r=s.slot.getSlotElementId();let a=[];r||a.push("id=0");const d=document.getElementById(r);if(r&&!d&&a.push("el=0"),0!==a.length)return void this.stalled(a.join("&"));const{path:l,sizes:c,zone:g}=(0,n.Z7)(r);if(this.collapsed[g]&&s.isEmpty)return e.cM(`No line item for the element #${d.id}... collapsing.`),void(0,o.wo)(d);if(this.slotsRenderedEvents.push(s),s.lineItemId||s.creativeId||!s.isEmpty){e.cM(`Rendered ad for element #${d.id} [line item #${s.lineItemId}]`),e.cM(s);var i=d.parentElement;if(i.classList.contains("js-zone-container")){switch((0,o.cf)(i),r){case"dfp-tlb":this.opt.tlb_position===t.Above?i.classList.add("mb8"):i.classList.add("mt16");break;case"dfp-tag":i.classList.add("mb8");break;case"dfp-msb":i.classList.add("mt16");break;case"dfp-mlb":case"dfp-smlb":case"dfp-bmlb":i.classList.add("my8");break;case"dfp-isb":i.classList.add("mt24");break;case"dfp-m-aq":i.classList.add("my12"),i.classList.add("mx-auto")}(0,o.$Z)(i),(0,o.$Z)(d)}else e.cM(`No ad for element #${d.id}, collapsing`),e.cM(s),(0,o.wo)(d)}}catch(t){e.cM("Exception thrown onSlotRendered"),e.cM(t),this.stalled("e=1")}}stalled(e){(new Image).src=`https://${this.clc_options.h}/stalled.gif?${e}`}defineSlot(t,s){"dfp-isb"===t&&(e.cM("-> targeting - Sidebar: Inline"),s.pubads().setTargeting("Sidebar",["Inline"])),"dfp-tsb"===t&&(e.cM("-> targeting - Sidebar: Right"),s.pubads().setTargeting("Sidebar",["Right"]));const{path:o,sizes:i,zone:r}=(0,n.Z7)(t);e.cM(`Defining slot for ${t}: ${o}, sizes: ${JSON.stringify(i)}`),s.defineSlot(o,i,t).addService(s.pubads())}importGptLibrary(){this.gptImported||(this.gptImported=!0,void 0===this.opt.targeting_consent||this.opt.targeting_consent?(0,o.Gx)("https://securepubads.g.doubleclick.net/tag/js/gpt.js"):(0,o.Gx)("https://pagead2.googlesyndication.com/tag/js/gpt.js"))}isGptReady(){return"undefined"!=typeof googletag&&!!googletag.apiReady}initGpt(){"undefined"==typeof googletag&&(window.googletag={cmd:(0,o.QZ)(()=>this.importGptLibrary())})}getUserAccountTargeting(){if(this.clc_options.tgt_e&&this.clc_options.tgt_p>0){if(e.cM("Targeting enabled."),this.clc_options.tgt_p<100){e.cM("Targeting rate limit enabled. Rolling the dice...");const t=Math.floor(100*Math.random())+1;if(e.cM("Rolled "+t+" and the max is "+this.clc_options.tgt_p),t>this.clc_options.tgt_p)return void e.cM("Will not request targeting.")}return e.cM("Will request targeting."),function(e,t,s){if(e){const e=new Headers;return e.append("Accept","application/json"),async function(e,t={},s=5e3){if("number"!=typeof s&&null!=s&&!1!==s){if("string"!=typeof s)throw new Error("fetchWithTimeout: timeout must be a number");if(s=parseInt(s),isNaN(s))throw new Error("fetchWithTimeout: timeout must be a number (or string that can be parsed to a number)")}const n=new AbortController,{signal:o}=n,i=fetch(e,{...t,signal:o}),r=setTimeout(()=>n.abort(),s);try{const e=await i;return clearTimeout(r),e}catch(e){throw clearTimeout(r),e}}(t,{method:"GET",mode:"cors",headers:e},s).then(e=>e.json())}return Promise.reject("No consent")}(this.opt.targeting_consent,this.clc_options.tgt_u,this.clc_options.tgt_to).catch(t=>{e.vU("Error fetching user account targeting"),e.vU(t)})}e.cM("Targeting disabled. Will not request account targeting data.")}initDebugPanel(t,s){e.cM("initDebugPanel"),e.cM("Not showing debug panel")}},window.clcGamLoaderOptions&&(cam.init(),cam.load())})()})();</script> 2293 2294 <footer id="footer" class="site-footer js-footer theme-light__forced" role="contentinfo"> 2295 <div class="site-footer--container"> 2296 <div class="site-footer--logo"> 2297 2298 <a href="https://stackoverflow.com" aria-label="Stack Overflow"><svg aria-hidden="true" class="native svg-icon iconLogoGlyphMd" width="32" height="37" viewBox="0 0 32 37"><path d="M26 33v-9h4v13H0V24h4v9h22Z" fill="#BCBBBB"/><path d="m21.5 0-2.7 2 9.9 13.3 2.7-2L21.5 0ZM26 18.4 13.3 7.8l2.1-2.5 12.7 10.6-2.1 2.5ZM9.1 15.2l15 7 1.4-3-15-7-1.4 3Zm14 10.79.68-2.95-16.1-3.35L7 23l16.1 2.99ZM23 30H7v-3h16v3Z" fill="#F48024"/></svg></a> 2299 </div> 2300 <nav class="site-footer--nav"> 2301 <div class="site-footer--col"> 2302 <h5 class="-title"><a href="https://stackoverflow.com" class="js-gps-track" data-gps-track="footer.click({ location: 2, link: 15})">Stack Overflow</a></h5> 2303 <ul class="-list js-primary-footer-links"> 2304 <li><a href="/questions" class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 16})">Questions</a></li> 2305 <li><a href="/help" class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 3 })">Help</a></li> 2306 </ul> 2307 </div> 2308 <div class="site-footer--col"> 2309 <h5 class="-title"><a href="https://stackoverflow.co/" class="js-gps-track" data-gps-track="footer.click({ location: 2, link: 19 })">Products</a></h5> 2310 <ul class="-list"> 2311 <li><a href="https://stackoverflow.co/teams/" class="js-gps-track -link" 2312 data-ga="["teams traffic","footer - site nav","stackoverflow.com/teams",null,{"dimension4":"teams"}]" 2313 data-gps-track="footer.click({ location: 2, link: 29 })">Teams</a></li> 2314 <li><a href="https://stackoverflow.co/advertising/" class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 21 })">Advertising</a></li> 2315 <li><a href="https://stackoverflow.co/collectives/" class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 40 })">Collectives</a></li> 2316 <li><a href="https://stackoverflow.co/talent/" class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 20 })">Talent</a></li> 2317 </ul> 2318 </div> 2319 <div class="site-footer--col"> 2320 <h5 class="-title"><a class="js-gps-track" data-gps-track="footer.click({ location: 2, link: 1 })" href="https://stackoverflow.co/">Company</a></h5> 2321 <ul class="-list"> 2322 <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 1 })" href="https://stackoverflow.co/">About</a></li> 2323 <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 27 })" href="https://stackoverflow.co/company/press/">Press</a></li> 2324 <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 9 })" href="https://stackoverflow.co/company/work-here/">Work Here</a></li> 2325 <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 7 })" href="https://stackoverflow.com/legal">Legal</a></li> 2326 <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 8 })" href="https://stackoverflow.com/legal/privacy-policy">Privacy Policy</a></li> 2327 <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 37 })" href="https://stackoverflow.com/legal/terms-of-service/public">Terms of Service</a></li> 2328 <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 13 })" href="https://stackoverflow.co/company/contact/">Contact Us</a></li> 2329 <li class="" id="consent-footer-link"><a class="js-gps-track -link js-cookie-settings" data-gps-track="footer.click({ location: 2, link: 38 })" href="#" data-consent-popup-loader="footer">Cookie Settings</a></li> 2330 <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link: 39 })" href="https://stackoverflow.com/legal/cookie-policy">Cookie Policy</a></li> 2331 </ul> 2332 </div> 2333 <div class="site-footer--col site-footer--categories-nav"> 2334 <div> 2335 <h5 class="-title"><a href="https://stackexchange.com" data-gps-track="footer.click({ location: 2, link: 30 })">Stack Exchange Network</a></h5> 2336 <ul class="-list"> 2337 <li> 2338 <a href="https://stackexchange.com/sites#technology" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 24 })"> 2339 Technology 2340 </a> 2341 </li> 2342 <li> 2343 <a href="https://stackexchange.com/sites#culturerecreation" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 24 })"> 2344 Culture & recreation 2345 </a> 2346 </li> 2347 <li> 2348 <a href="https://stackexchange.com/sites#lifearts" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 24 })"> 2349 Life & arts 2350 </a> 2351 </li> 2352 <li> 2353 <a href="https://stackexchange.com/sites#science" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 24 })"> 2354 Science 2355 </a> 2356 </li> 2357 <li> 2358 <a href="https://stackexchange.com/sites#professional" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 24 })"> 2359 Professional 2360 </a> 2361 </li> 2362 <li> 2363 <a href="https://stackexchange.com/sites#business" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 24 })"> 2364 Business 2365 </a> 2366 </li> 2367 2368 <li class="mt16 md:mt0"> 2369 <a href="https://api.stackexchange.com/" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 24 })"> 2370 API 2371 </a> 2372 </li> 2373 2374 <li> 2375 <a href="https://data.stackexchange.com/" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 24 })"> 2376 Data 2377 </a> 2378 </li> 2379 </ul> 2380 </div> 2381 </div> 2382 </nav> 2383 <div class="site-footer--copyright fs-fine md:mt24"> 2384 <ul class="-list -social md:mb8"> 2385 <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 2, link:4 })" href="https://stackoverflow.blog?blb=1">Blog</a></li> 2386 <li><a href="https://www.facebook.com/officialstackoverflow/" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 31 })">Facebook</a></li> 2387 <li><a href="https://twitter.com/stackoverflow" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 32 })">Twitter</a></li> 2388 <li><a href="https://linkedin.com/company/stack-overflow" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 33 })">LinkedIn</a></li> 2389 <li><a href="https://www.instagram.com/thestackoverflow" class="-link js-gps-track" data-gps-track="footer.click({ location: 2, link: 36 })">Instagram</a></li> 2390 </ul> 2391 2392 <p class="md:mb0"> 2393 Site design / logo © 2023 Stack Exchange Inc; user contributions licensed under <span class='td-underline'><a href="https://stackoverflow.com/help/licensing">CC BY-SA</a></span>. <span id="svnrev">rev 2023.11.30.1842</span> 2394 </p> 2395 </div> 2396 </div> 2397 2398 </footer> 2399 2400 2401 2402 2403 <!-- Google tag (gtag.js) --> 2404 <script async src="https://www.googletagmanager.com/gtag/js?id=G-WCZ03SZFCQ"></script> 2405 <script> 2406 window.dataLayer = window.dataLayer || []; 2407 function gtag() { dataLayer.push(arguments); } 2408 </script> 2409 <script> 2410 StackExchange.ready(function() { 2411 2412 var ga3Settings = { 2413 autoLink: ["stackoverflow.blog","info.stackoverflowsolutions.com","stackoverflowsolutions.com"], 2414 sendTitles: true, 2415 tracker: window.ga, 2416 trackingCodes: [ 2417 'UA-108242619-1' 2418 ], 2419 checkDimension: 'dimension42' 2420 }; 2421 2422 var customGA4Dimensions = {}; 2423 2424 2425 customGA4Dimensions["routename"] = "Questions/Show"; 2426 2427 2428 customGA4Dimensions["post_id"] = "20626994"; 2429 2430 customGA4Dimensions["tags"] = "|python|scipy|normal-distribution|"; 2431 2432 2433 var ga4Settings = { 2434 tracker: gtag, 2435 trackingCodes: [ 2436 'G-WCZ03SZFCQ' 2437 ], 2438 consentsToPerformanceCookies: "denied", 2439 consentsToTargetingCookies: "denied", 2440 eventParameters: customGA4Dimensions, 2441 checkForAdBlock: true, 2442 sendTitles: true, 2443 trackClicks: false, 2444 }; 2445 2446 StackExchange.ga.init({ GA3: ga3Settings, GA4: ga4Settings }); 2447 2448 2449 StackExchange.ga.setDimension('dimension2', '|python|scipy|normal-distribution|'); 2450 2451 2452 StackExchange.ga.setDimension('dimension3', 'Questions/Show'); 2453 2454 2455 StackExchange.ga.setDimension('dimension7', "1701628369.1770797741"); 2456 2457 StackExchange.ga.trackPageView(); 2458 }); 2459 </script> 2460 2461 2462 <div class="ff-sans ps-fixed z-nav-fixed ws4 sm:w-auto p32 sm:p16 bg-black-600 fc-white bar-lg b16 l16 r16 js-consent-banner"> 2463 <svg aria-hidden="true" class="mln4 mb24 sm:d-none svg-spot spotCookieLg" style="color: var(--theme-button-primary-background-color, var(--theme-primary-200))" width="96" height="96" viewBox="0 0 96 96"> 2464 <path d="M35 45.5a7.5 7.5 0 11-15 0 7.5 7.5 0 0115 0zM63.5 63a7.5 7.5 0 100-15 7.5 7.5 0 000 15zm-19 19a7.5 7.5 0 100-15 7.5 7.5 0 000 15z" opacity=".2" /> 2465 <path d="M56.99 2.53a23.1 23.1 0 0114.66 6.15h.01l.01.02c.57.55.61 1.27.5 1.74v.07a10.95 10.95 0 01-3.07 4.77 9 9 0 01-6.9 2.5 10.34 10.34 0 01-9.72-10.44v-.08a10 10 0 011.03-3.74l.01-.03.02-.02c.28-.5.82-.92 1.52-.95.63-.02 1.27-.02 1.93.01zm12.04 7.83a20.1 20.1 0 00-12.2-4.83l-.92-.03c-.23.6-.38 1.25-.43 1.94a7.34 7.34 0 006.95 7.34 6 6 0 004.64-1.7c.94-.88 1.6-1.9 1.96-2.72zm15.3 8.76a6.84 6.84 0 00-5.09-.24 7.9 7.9 0 00-3.28 2.05 1.8 1.8 0 00-.3 1.95l.02.02v.02a15.16 15.16 0 008.74 7.47c.64.23 1.32.08 1.8-.33a6.63 6.63 0 001.63-1.97l.01-.03.01-.03c1.67-3.5-.12-7.32-3.54-8.91zm-5.5 3.28c.36-.25.82-.5 1.35-.67.92-.3 1.92-.35 2.89.1 2.14 1 2.92 3.14 2.11 4.88-.12.21-.26.41-.43.6l-.26-.1a12.29 12.29 0 01-5.66-4.81zM32 24a2 2 0 11-4 0 2 2 0 014 0zm12 21a2 2 0 11-4 0 2 2 0 014 0zm36 4a2 2 0 11-4 0 2 2 0 014 0zm-7 21a2 2 0 11-4 0 2 2 0 014 0zM59 81a2 2 0 11-4 0 2 2 0 014 0zM22 63a2 2 0 11-4 0 2 2 0 014 0zm27 7a9 9 0 11-18 0 9 9 0 0118 0zm-3 0a6 6 0 10-12 0 6 6 0 0012 0zM33 41a9 9 0 11-18 0 9 9 0 0118 0zm-15 0a6 6 0 1012 0 6 6 0 00-12 0zm50 11a9 9 0 11-18 0 9 9 0 0118 0zm-3 0a6 6 0 10-12 0 6 6 0 0012 0zM44.08 4.24c.31.48.33 1.09.05 1.58a17.46 17.46 0 00-2.36 8.8c0 9.55 7.58 17.24 16.85 17.24 2.97 0 5.75-.78 8.16-2.15a1.5 1.5 0 012.1.66 12.08 12.08 0 0011 6.74 12.4 12.4 0 007.85-2.75 1.5 1.5 0 012.38.74A45.76 45.76 0 0192 48.16c0 24.77-19.67 44.9-44 44.9S4 72.93 4 48.16C4 25.23 20.84 6.28 42.64 3.58a1.5 1.5 0 011.44.66zM40.22 7C21.32 10.71 7 27.7 7 48.16c0 23.17 18.39 41.9 41 41.9s41-18.73 41-41.9c0-3.52-.42-6.93-1.22-10.2a15.5 15.5 0 01-7.9 2.15c-5.5 0-10.36-2.83-12.97-7.1a19.46 19.46 0 01-8.28 1.85c-11 0-19.86-9.1-19.86-20.24 0-2.7.52-5.26 1.45-7.62zM92 91a2 2 0 100-4 2 2 0 000 4zM7 8.5a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0zM82.5 90a1.5 1.5 0 100-3 1.5 1.5 0 000 3zm9.5-7.5a1.5 1.5 0 11-3 0 1.5 1.5 0 013 0zM13.5 8a1.5 1.5 0 100-3 1.5 1.5 0 000 3zM80 14.5a1.5 1.5 0 11-3 0 1.5 1.5 0 013 0zM53.5 20a1.5 1.5 0 100-3 1.5 1.5 0 000 3z" /> 2466 </svg> 2467 <p class="fs-body2 fw-bold mb4"> 2468 Your privacy 2469 </p> 2470 <p class="mb16 s-anchors s-anchors__inherit s-anchors__underlined"> 2471 By clicking “Accept all cookies”, you agree Stack Exchange can store cookies on your device and disclose information in accordance with our <a href="https://stackoverflow.com/legal/cookie-policy">Cookie Policy</a>. 2472 </p> 2473 <div class="d-flex gs8 sm:fd-column"> 2474 <button class="flex--item6 s-btn s-btn__filled js-accept-cookies js-consent-banner-hide"> 2475 Accept all cookies 2476 </button> 2477 2478 <button class="flex--item6 s-btn s-btn__filled js-reject-cookies js-consent-banner-hide"> 2479 Necessary cookies only 2480 </button> 2481 </div> 2482 2483 <div class="d-flex mt8 sm:fd-column"> 2484 <button class="flex--item12 s-btn s-btn__filled js-cookie-settings" data-consent-popup-loader="banner"> 2485 Customize settings 2486 </button> 2487 </div> 2488 </div> 2489 <div id="onetrust-consent-sdk" class="d-none"></div> 2490 <div id="onetrust-banner-sdk" data-controller="s-modal"></div> 2491 <div id="ot-pc-content" class="d-none"></div> 2492 <div id="onetrust-style" class="d-none"> </div> 2493 <div class="d-none js-consent-banner-version" data-consent-banner-version="1"></div> 2494 2495 2496 2497 </body> 2498 </html>