[SciPy-User] Survival vs 1-cdf clarification

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[SciPy-User] Survival vs 1-cdf clarification

Olga Botvinnik
For the random variables in scipy.stats, I have a question about the documentation. Does the statement "Survival function (1-cdf — sometimes more accurate)." mean:

1. Survival function (also defined as 1-cdf, and the survival function version is sometimes more accurate).
-- or --
2. Survival function (also defined as 1-cdf, and 1-cdf is sometimes more accurate).

Thanks!
Olga

_______________________________________________
SciPy-User mailing list
[hidden email]
https://mail.scipy.org/mailman/listinfo/scipy-user
Reply | Threaded
Open this post in threaded view
|

Re: Survival vs 1-cdf clarification

Robert Kern-2

On Thu, Dec 3, 2015 at 6:04 PM, Olga Botvinnik <[hidden email]> wrote:
>
> For the random variables in scipy.stats, I have a question about the documentation. Does the statement "Survival function (1-cdf — sometimes more accurate)." mean:
>
> 1. Survival function (also defined as 1-cdf, and the survival function version is sometimes more accurate).

This one.

--
Robert Kern

_______________________________________________
SciPy-User mailing list
[hidden email]
https://mail.scipy.org/mailman/listinfo/scipy-user
Reply | Threaded
Open this post in threaded view
|

Re: Survival vs 1-cdf clarification

josef.pktd
In reply to this post by Olga Botvinnik


On Thu, Dec 3, 2015 at 1:04 PM, Olga Botvinnik <[hidden email]> wrote:
For the random variables in scipy.stats, I have a question about the documentation. Does the statement "Survival function (1-cdf — sometimes more accurate)." mean:

1. Survival function (also defined as 1-cdf, and the survival function version is sometimes more accurate).
-- or --
2. Survival function (also defined as 1-cdf, and 1-cdf is sometimes more accurate).

 
the second part means:  using sf is in many cases more accurate than 1 - cdf
This applies when we want to evaluate probabilities in the right tail.

1 - norm.cdf(20) is worse than sf(20)      


For some distribution there is no explicit sf implementation, then internally it's also sf = 1 - cdf by default, and accuracy can be low far in the tail.

Josef




 
Thanks!
Olga

_______________________________________________
SciPy-User mailing list
[hidden email]
https://mail.scipy.org/mailman/listinfo/scipy-user



_______________________________________________
SciPy-User mailing list
[hidden email]
https://mail.scipy.org/mailman/listinfo/scipy-user
Reply | Threaded
Open this post in threaded view
|

Re: Survival vs 1-cdf clarification

Olga Botvinnik
Ah okay. I find the langauge and punctuation unclear. What about rewording the documentation to "Survival function (sometimes more accurate than the alternate definition of 1-cdf)." or equivalent? I'm happy to submit a PR

On Thu, Dec 3, 2015 at 10:18 AM <[hidden email]> wrote:
On Thu, Dec 3, 2015 at 1:04 PM, Olga Botvinnik <[hidden email]> wrote:
For the random variables in scipy.stats, I have a question about the documentation. Does the statement "Survival function (1-cdf — sometimes more accurate)." mean:

1. Survival function (also defined as 1-cdf, and the survival function version is sometimes more accurate).
-- or --
2. Survival function (also defined as 1-cdf, and 1-cdf is sometimes more accurate).

 
the second part means:  using sf is in many cases more accurate than 1 - cdf
This applies when we want to evaluate probabilities in the right tail.

1 - norm.cdf(20) is worse than sf(20)      


For some distribution there is no explicit sf implementation, then internally it's also sf = 1 - cdf by default, and accuracy can be low far in the tail.

Josef




 
Thanks!
Olga

_______________________________________________
SciPy-User mailing list
[hidden email]
https://mail.scipy.org/mailman/listinfo/scipy-user

_______________________________________________
SciPy-User mailing list
[hidden email]
https://mail.scipy.org/mailman/listinfo/scipy-user

_______________________________________________
SciPy-User mailing list
[hidden email]
https://mail.scipy.org/mailman/listinfo/scipy-user
Reply | Threaded
Open this post in threaded view
|

Re: Survival vs 1-cdf clarification

josef.pktd


On Thu, Dec 3, 2015 at 1:30 PM, Olga Botvinnik <[hidden email]> wrote:
Ah okay. I find the langauge and punctuation unclear. What about rewording the documentation to "Survival function (sometimes more accurate than the alternate definition of 1-cdf)." or equivalent? I'm happy to submit a PR

Please do. documentation improvements are always useful. This phrasing is most likely ancient.

BTW:   [ci skip] in the commit message avoids a TravisCI run which is not needed for pure documentation changes.

Josef

 

On Thu, Dec 3, 2015 at 10:18 AM <[hidden email]> wrote:
On Thu, Dec 3, 2015 at 1:04 PM, Olga Botvinnik <[hidden email]> wrote:
For the random variables in scipy.stats, I have a question about the documentation. Does the statement "Survival function (1-cdf — sometimes more accurate)." mean:

1. Survival function (also defined as 1-cdf, and the survival function version is sometimes more accurate).
-- or --
2. Survival function (also defined as 1-cdf, and 1-cdf is sometimes more accurate).

 
the second part means:  using sf is in many cases more accurate than 1 - cdf
This applies when we want to evaluate probabilities in the right tail.

1 - norm.cdf(20) is worse than sf(20)      


For some distribution there is no explicit sf implementation, then internally it's also sf = 1 - cdf by default, and accuracy can be low far in the tail.

Josef




 
Thanks!
Olga

_______________________________________________
SciPy-User mailing list
[hidden email]
https://mail.scipy.org/mailman/listinfo/scipy-user

_______________________________________________
SciPy-User mailing list
[hidden email]
https://mail.scipy.org/mailman/listinfo/scipy-user

_______________________________________________
SciPy-User mailing list
[hidden email]
https://mail.scipy.org/mailman/listinfo/scipy-user



_______________________________________________
SciPy-User mailing list
[hidden email]
https://mail.scipy.org/mailman/listinfo/scipy-user