similar to: Bisection in R

Displaying 20 results from an estimated 40000 matches similar to: "Bisection in R"

2010 Sep 10
3
Is there a bisection method in R?
Dear fellow R-users, Is there a function that does the bisection method? I was unable to find one. Thanks in advance. Gregory [[alternative HTML version deleted]]
2012 Nov 08
3
vectorized uni-root?
dear R experts--- I have (many) unidimensional root problems. think loc.of.root <- uniroot( f= function(x,a) log( exp(a) + a) + a, c(.,9e10), a=rnorm(1) ) $root (for some coefficients a, there won't be a solution; for others, it may exceed the domain. implied volatilities in various Black-Scholes formulas and variant formulas are like this, too.) except I don't need 1 root, but a
2005 Jan 29
2
Name conflicts when passing arguments for one function to another
I am fairly new to R. I find it surprising that f <- function(x,a) {x-a} uniroot(f, c(0,1), a=.5) works, but integrate(f, 0, 1, a=.5) gives an error: Error in integrate(f, 0, 1, a = 0.5) : argument 4 matches multiple formal arguments What is the best way of avoiding such surprises? Is there a way of telling integrate() that the 'a' argument is for f()? If I wrote my own function
2010 Aug 25
4
Secant Method Convergence (Method to replicate Excel XIRR/IRR)
Hi, I am new to R, and as a first exercise, I decided to try to implement an XIRR function using the secant method. I did a quick search and saw another posting that used the Bisection method but wanted to see if it was possible using the secant method. I would input a Cash Flow and Date vector as well as an initial guess. I hardcoded today's initial date so I could do checks in Excel.
2003 Mar 08
2
Looking for non-central F quantile
Greetings all, I'm trying to figure out how to calculate the inverse CDF (i.e. a quantile) for a non-central F distribution. I could put together a quick numerical solver routine using the CDF, but I wonder if there's a function that I've missed that would be more efficient? Thank-you, Andrew Andrew Robinson Ph: 208 885 7115 Department of Forest Resources Fa: 208 885
2009 Mar 16
1
Uniroot and Newton-Raphson Anomaly
I have the following function for which I need to find the root of a: f <- function(R,a,c,q) sum((1 - (1-R)^a)^(1/a)) - c * q To give context for the problem, this is a psychometric issue where R is a vector denoting the percentage of students scoring correct on test item i in class j, c is the proportion correct on the test by student k, and q is the number of items on the test in total. I
2011 Feb 21
1
question about solving equation using bisection method
Hi all, I have the following two function f1 and f2. f1 <- function(lambda,z,p1){ lambda*(p1*exp(-3*z-9/2)+(0.2-p1)*exp(4*z-8))-(1-lambda)*0.8} f2 <- function(p1,cl, cu){ 0.8*(pnorm(cl)+(1-pnorm(cu)))/(0.8*(pnorm(cl)+(1-pnorm(cu)))+p1*(pnorm(cl+3)+(1-pnorm(cu+3)))+(0.2-p1)*(pnorm(cl-4)+(1-pnorm(cu-4))))}-0.05 First fix p1 to be 0.15. (i) choose a lambda value, say lamda=0.6, (ii)
2000 Jun 15
1
proportions - finite population correction
> Dear R-users! > > I am using R 1.0.0 and Windows NT 4.0. > Suppose I have a population of N=100 subjects, a binomial variable and a random sample of n=20 subjects from my population, giving 15 "successes". I am interested in obtaining a confidence interval for the proportion of "successes" in my population. In R, I can use > library(ctest) >
1999 Apr 23
1
[S] uniroot -- doesn't work recursively
Dear Prof Azzalini, You have an interesting example of recursive use of uniroot(). [re-cited at the end] However, note that R currently has the same problem as S-plus: Uniroot() doesn't work reliably, recursively. When you found it to be better, you were just lucky. The relevant file in R's source, src/main/optimize.c says /* WARNING : As things stand, these routines should
2004 Jan 22
1
error message
Hi, Can someone please tell me what such an error message could mean. i.e where a problem must have arised. Error in uniroot(function(n) eval(p.body) - power, c(2, 1e+07)) : f() values at end points not of opposite sign Thank you cilver ===== ===================== Sylvie B. Forkusam Eppelheimer Str.52/A2-5-2 69115 Heidelberg, Germany Tel: (0049)-06221/346913 Mobile: 0179-6816276
2018 Dec 07
2
next/master boot bisection: Oops in nouveau driver on jetson-tk1
Please find below an automated bisection report for a kernel Oops seen during the initialisation of the nouveau GPU driver on jetson-tk1. All the LAVA test jobs for this bisection can be found here: http://lava.baylibre.com:10080/scheduler/alljobs?length=25&search=lava-bisect-staging-7366#table Here's the beginning of the Oops stack trace: [ 7.485361] [00000064] *pgd=f9e7b835 [
2018 Dec 10
2
next/master boot bisection: Oops in nouveau driver on jetson-tk1
On 08/12/2018 00:08, Lyude Paul wrote: > uhhhhhhhhhhhhh > didn't we fix this weeks ago? with "drm/nouveau: tegra: Call > nouveau_drm_device_init()" Yes here's the fix from Thierry: https://patchwork.freedesktop.org/patch/263587/ and I can confirm that it does fix the Oops when applied on top of next-20181206 (what I used for the bisection last week):
2001 May 07
1
qt with ncp?
Does anybody has a function or idea how to calculate qt with a noncentrality parameter? I'm porting a SAS-macro for equivalence (Wellek, 1994 TT2ST) to R and it seems that I need this to calculate tinv (SAS-command, I hope that this is R's qt,...I get the SAS-macro manual next week). thanks Peter -- P.Malewski, Limmerstr.47, 30451 Hannover, 0511-2135008 At work:
2011 Apr 02
1
uniroot speed and vectorization?
curiosity---given that vector operations are so much faster than scalar operations, would it make sense to make uniroot vectorized? if I read the uniroot docs correctly, uniroot() calls an external C routine which seems to be a scalar function. that must be slow. I am thinking a vectorized version would be useful for an example such as of <- function(x,a) ( log(x)+x+a ) uniroot( of, c(
2013 Sep 14
3
[xen-unstable bisection] complete build-i386
branch xen-unstable xen branch xen-unstable job build-i386 test xen-build Tree: qemuu git://xenbits.xen.org/staging/qemu-upstream-unstable.git Tree: xen git://xenbits.xen.org/xen.git *** Found and reproduced problem changeset *** Bug is in tree: xen git://xenbits.xen.org/xen.git Bug introduced: ae763e4224304983a1cde2fbb3d6e0c4d60b2688 Bug not present:
2013 Mar 13
1
Fwd: [bisected] nouveau failure with 3.9-rc1 and ongoing
Hiya, I sent the enclosed email to linux-kernel before realizing that it would, perhaps, be more proper to send it here, which I hereby do. I shall be happy to try out any and all patches. Best regards, Sune M?lgaard -------- Original Message -------- Subject: [bisected] nouveau failure with 3.9-rc1 and ongoing Date: Tue, 12 Mar 2013 19:57:55 +0100 From: Sune M?lgaard <sune at
2015 Oct 08
2
beta: cloud compiler bisection tool
I am happy to announce we are contributing one of our favorite internal tools: llvm bisect! First: I want to thank Daniel Dunbar for writing all the code for this tool, and Google for providing cloud storage and bandwidth to host it! We keep the compilers we build in the Green Dragon CI cluster, and now upload them to the Google Storage Cloud. The llvmlab bisect tool, takes those compilers
2000 Feb 24
1
fisher.test() in ctest or perhaps uniroot() (PR#455)
fisher.test(matrix(c(1,20,246,6873),2),hybrid=F) Error in if (f(lower, ...) * f(upper, ...) >= 0) stop("f() values at end points not of opposite sign") : missing value where logical needed Thomas Lumley Assistant Professor, Biostatistics University of Washington, Seattle -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-devel mailing list --
2007 Oct 26
5
help
hello, please can anyone help me out. Am a new user of R program. Am having problem with this code below, not getting the expected results. 1. Each m, the cumulative sum should be 1.000 but the 2nd and 3rd m returned 2.000 and 3.000 instead of 1.000. 2. to get the LCL(m) and UCL(m) for each m base on these instructions if out.cum > 0.025 then LCL(m)= y-1 if out.cum >0.975
2005 Apr 07
3
R-beta 2004-04-07 build failed on AIX
I thought I'd give this another shot before the official release. I tried building R-beta_2004-04-07 on the AIX system that I have access to, and it seemed to failed at lazy-loading survival. I'd very much appreciate any pointer on what to try or look for next. 1. I set OBJECT_MODE to 64 for building 64-bit binary. 2. I edited config.site with the following: CC="xlc_r"