Hi, I'm trying to find the corresponding Fortran77 subroutines for R function pt(). I tried some Fortran77 subroutines to compute the t distribution function. But none of them are as good as R function pt(). Does anyone can give me some information about it? Thank you very much! Tianyue
Huntsinger, Reid
2005-Mar-14 18:20 UTC
[R] The corresponding Fortran77 codes for R function pt()
The routine "pt" is in the numerical mathematics library, in src/nmath if you untar the source distribution of R. It's in C, though, not Fortran. You can write Fortran wrappers for it. Reid Huntsinger -----Original Message----- From: r-help-bounces at stat.math.ethz.ch [mailto:r-help-bounces at stat.math.ethz.ch] On Behalf Of tianyue Sent: Monday, March 14, 2005 12:58 PM To: r-help at stat.math.ethz.ch Subject: [R] The corresponding Fortran77 codes for R function pt() Hi, I'm trying to find the corresponding Fortran77 subroutines for R function pt(). I tried some Fortran77 subroutines to compute the t distribution function. But none of them are as good as R function pt(). Does anyone can give me some information about it? Thank you very much! Tianyue ______________________________________________ R-help at stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Thomas Lumley
2005-Mar-14 18:25 UTC
[R] The corresponding Fortran77 codes for R function pt()
On Mon, 14 Mar 2005, tianyue wrote:> Hi, > > I'm trying to find the corresponding Fortran77 subroutines for R function > pt(). I tried some Fortran77 subroutines to compute the t distribution > function. But none of them are as good as R function pt(). Does anyone can > give me some information about it? >There is no Fortran subroutine (although some of the C functions are translations of Fortran). The C code is in any R source distribution, in src/nmath/pt.c. It also calls src/nmath/pbeta.c. The comments in the code say where the algorithms came from. -thomas
Uwe Ligges
2005-Mar-14 18:32 UTC
[R] The corresponding Fortran77 codes for R function pt()
tianyue wrote:> Hi, > > I'm trying to find the corresponding Fortran77 subroutines for R > function pt(). I tried some Fortran77 subroutines to compute the t > distribution function. But none of them are as good as R function pt(). > Does anyone can give me some information about it?Well, you can download the sources and take a look... Who told you that it is in Fortran? Uwe Ligges> Thank you very much! > > Tianyue > > ______________________________________________ > R-help at stat.math.ethz.ch mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide! > http://www.R-project.org/posting-guide.html
Duncan Murdoch
2005-Mar-14 18:48 UTC
[R] The corresponding Fortran77 codes for R function pt()
On Mon, 14 Mar 2005 11:57:39 -0600, tianyue <tzhou1 at uiuc.edu> wrote :>Hi, > >I'm trying to find the corresponding Fortran77 subroutines for R >function pt(). I tried some Fortran77 subroutines to compute the t >distribution function. But none of them are as good as R function pt(). >Does anyone can give me some information about it?Others have pointed you to the source code for that function. You may also want to call it directly: R exports some functions with C interfaces (that should be callable from Fortran, too). See the R API chapter in the Writing R Extensions manual. Duncan Murdoch