similar to: dfsane arguments

Displaying 20 results from an estimated 100 matches similar to: "dfsane arguments"

2011 Apr 28
1
DLSODA error
Dear R-users, I'm running an MLE procedure where some ODEs are solved for each iteration in the maximization process. I use mle2 for the Maximum likelihood and deSolve for the ODEs. The problem is that somewhere along the way the ODE solver crashes and I get the following error message: DLSODA- Warning..Internal T (=R1) and H (=R2) are such that in the machine, T + H = T on the next
2011 Dec 07
1
Output table from for loop
Hi, this might be basic but can't get it to work and it is hampering my R usage: #the loop is checking variance of rows, and cutting out rows with var>numVec[i] #I define outMat as object names I want to output to (does this make sense? how else #can I define sequential numbered output?) #numVec is numbers I use in the loop head(Counts) AN1 AN2 AN3 AN4 var GENE1
2011 Sep 02
1
Using capture.output within a function
Dear R-users I'm running a maximum likelihood procedure using the spg package. I'd like to save some output produced in each iteration to a file, but if I put the capture.output() within the function I get the following message; Error in spg(par = startval, fn = loglik, gr = NULL, method = 3, lower = lo, : Failure in initial function evaluation!Error in -fn(par, ...) : invalid argument
2002 Feb 11
0
profile
I am running 1.3.1 on a Windows (NT 4.0) machine. I've fit a nonlinear model intended to predict crop yield from nutrient information, and want to use the profile function. If I type say, profile(simparj.fm) I get the following error message: "Error in prof$getProfile(): number of iterations exceeded maximum of 5.25515e-308" I used the profiler function to profile simparj,fm step
2011 Apr 23
2
Loop and Solver with Black/Scholes-Formula
Hello, for my diploma thesis I need to program a solver for Merton?s respectively Black?s and Scholes? Option pricing formula, which should be achieved for several dates. What I want to do is to estimate the value of a firm?s assets "vA" (x[2] denotes vA) and the option-implied volatility of firm?s assets "sigA" (x[1] denotes sigA) by solving it simultaneous using the Black
2010 Apr 29
1
BB package
Hi I would like to solve a system of nonlinear equations below using dfsane function   mn <- 142.36; vr <- 9335.69 ; sk <- 0.81;  kur <- 0.25 test_fn <- function(p) {    f <- rep(NA, length(p))     f[1] <- p[1]*(p [2]+p[3])- mn   f[2] <- - vr + 2*p[1]*p[2]*p[3]*(p[4]-1)+p[1]*(p[2]+p[3])^2   f[3] <- - sk + (p[1]*(p [2]+p[3])^3*(p[1]+1)*(p[1]+2)-6*p[1]*p[2]*p[3]*(p[2]+
2010 Mar 11
4
help about solving two equations
I have two matrix s1 and s2, each of them is 1000*1. and I have two equations: digamma(p)-digamma(p+q)=s1, digamma(q)-digamma(p+q)=s2, and I want to sovle these two equations to get the value of x and y, which are also two 1000*1 matrices. I write a program like this: f <- function(x) { p<- x[1]; q <- x[2]; ((digamma(p)-digamma(p+q)-s1[2,]) )^2 +((digamma(q)-digamma(p+q)-s2[2,]) )^2
2010 Nov 21
1
solve nonlinear equation using BBsolve
Hi r-users, I would like to solve system of nonlinear equation using BBsolve function and below is my code.  I have 4 parameters and I have 4 eqns. mgf_gammasum <- function(p) { t  <- rep(NA, length(p)) mn <- 142.36 vr <- 9335.69 sk <- 0.8139635 kur <- 3.252591 rh  <- 0.896 # cumulants k1 <- p[1]*(p[2]+p[3]) k2 <- p[1]*(2*p[2]*p[3]*p[4] +p[2]^2+p[3]^2) k3 <-
2011 Aug 05
2
Which is more efficient?
Greetings all, I am curious to know if either of these two sets of code is more efficient? Example1: ## t-test ## colA <- temp [ , j ] colB <- temp [ , k ] ttr <- t.test ( colA, colB, var.equal=TRUE) tt_pvalue [ i ] <- ttr$p.value or Example2: tt_pvalue [ i ] <- t.test ( temp[ , j ], temp[ , k ], var.equal=TRUE) ------------- I have three loops, i, j, k. One to test the all of
2009 Mar 23
4
newton method
Hi R-users, Does R has a topic on newton's method? Thank you for the info.
2009 Jul 17
6
Solving two nonlinear equations with two knowns
Dear R users, I have two nonlinear equations, f1(x1,x2)=0 and f2(x1,x2)=0. I try to use optim command by minimize f1^2+f2^2 to find x1 and x2. I found the optimal solution changes when I change initial values. How to solve this? BTW, I also try to use grid searching. But I have no information on ranges of x1 and x2, respectively. Any suggestion to solve this question? Thanks, Kate
2009 Nov 27
1
generating a matrix after a for loop..
Hi all, I have to ask this and I know that the reason is that I am a newbie with R programming. So apologize if it is too obvious but I didn't find an answer after googling and reading "An introduction to R". So i have return data from 30 instruments and I am fitting a mixture of normal distributions for the asymmetric marginal distributions and then simulating from those
2008 Apr 25
5
Non-linear system of equations
Hello R users, I am trying to estimate the parameters of a bimodal normal distribution using moments matching, so I have to solve a non-linear system of equations. How can I solve the following simple example? x^2 - y^2 = 6 x ? y = 3 I heard about nlsystemfit, but I don?t know how to run it exactly. I have tried the following code, but it doesn?t really work: f1 <-y~ x[1]^2-x[2]^2-6 f2
2009 Jul 23
1
Non-negative solutions to complicated equations
Hi all, I have a system of 3 equations with many defined parameters and 3 variables I need to find solutions to. I actually know the solutions I'm aiming for (0.07,0.287,0.0061) but R tends to give me (0,0,0). I tried the "BB" package but don't really follow how to refine my solutions from that; these are wrong so far. Here's my code from trying that: > f<-function(x){
2009 Apr 20
1
Two or more dimensional root (Zero) finding
Good morning to all, I should find the zero of a specific function with respect to a vector of arguments. Does it exist something similar in R? Thank you very much, Enrico Foscolo
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
2004 Sep 21
3
how to take this experiment with R?
How about: x <- data.frame(matrix(rnorm(1550),c(50,31))) model <- step(lm(x[,1] ~ as.matrix(x[,2:31]))) --Matt -----Original Message----- From: r-help-bounces at stat.math.ethz.ch [mailto:r-help-bounces at stat.math.ethz.ch]On Behalf Of rongguiwong Sent: Monday, September 20, 2004 20:52 PM To: r-help at stat.math.ethz.ch Subject: [R] how to take this experiment with R? This message uses
2009 Feb 25
1
leaps question
Colleagues, please help me with the simple question. How can I find R2 and p while doing best subsets regression? Also how can I see B and p for coefficients? Maybe you can advice me detailed manual, because in manual for the package this is not described. Thank you
2007 Aug 08
1
Regsubsets statistics
Dear R-help, I have used the regsubsets function from the leaps package to do subset selection of a logistic regression model with 6 independent variables and all possible ^2 interactions. As I want to get information about the statistics behind the selection output, I?ve intensively searched the mailing list to find answers to following questions: 1. What should I do to get the statistics
2009 Mar 17
3
Non-Linear Optimization - Query
Dear All, I couple of weeks ago, I’ve asked for a package recommendation for nonlinear optimization. In my problem I have a fairly complicated non-linear objective function subject to one non-linear equality constrain. I’ve been suggested to use the *Rdonlp2* package, but I did not get any results after running the program for 5 hrs. Is it normal to run this type of programs for hours? Also,