Displaying 20 results from an estimated 4000 matches similar to: "ErrError in f(x, ...) : object 'g.' not found"
2011 Aug 18
3
Error message: object of type 'closure' is not subsettable
Dear R-users
I need to calibrate kappa, rho, eta, theta, v0 in the following code, see
below. However when I run it, I get:
y <- function(kappahat, rhohat, etahat, thetahat, v0hat) {sum(difference(k,
t, S0, X, r, implvol, q, kappahat, rhohat, etahat, thetahat, v0hat)^2)}
> nlminb(start=list(kappa, rho, eta, theta, v0), objective = y, lower =lb,
> upper =ub)
Error in dots[[1L]][[1L]] :
2007 Oct 18
1
R-graphics printing greeks
I have tried to print a table of greek alphabet names and symbols
without success. I can print one character at a time but can't seem to
find a way to automate an entire list of the symbols. Some of the code I
have tried is below. I have searched on help, worked the examples in the
December 2002 R Help Desk article and plotmath but have not been able
to find a way to accomplish the
2012 Mar 29
1
Error, Variable is Missing
Hi, I am writing a function to plot a pdf of a distribution,
GNL.pdf.fn = function(x,mu,sigma,alpha,beta,rho)
{
y = x-rho*mu
cf.fn = function(s){
cplex = complex(1,0,1)
temp1 = alpha*beta*exp(-sigma*s^2/2)
temp2 = (alpha-cplex*s)*(beta+cplex*s)
out = (temp1/temp2)^rho
out
}
temp.fn = function(s){
(Mod(cf.fn(s)))*cos(Arg(cf.fn(s))-s*y)
}
int.fn =
2010 May 24
2
How to set parameters constraints in a function?
Dear R list,
I have a function specifying my log-likelihood, and now I need to set the
constraint that *alpha > kappa*, could anyone help me with setting this in
my function?
the function is defined as follows:
mll <- function(param){
n <- length(x)
psi <- numeric(n)
psi[1] <- 1.0
a0 <- exp(param[1]); a1 <-exp(param[2]); b1 <- exp(param[3]); *alpha *<-
2007 Mar 22
3
Cohen's Kappa
Hi,
im little bit confused about Cohen's Kappa and i should be look into the
Kappa function code. Is the easy formula really wrong?
kappa=agreement-chance/(1-chance)
many thanks
christian
###############################################################################
true-negativ:7445
false-positive:3410
false-negativ:347
true-positiv:772
classification-aggrement:68,6%
2009 Aug 12
1
MCMC sampling question
Hello,
Consider MCMC sampling with metropolis / metropolis hastings proposals
and a density function with a given valid parameter space. How are MCMC
proposals performed if the parameter could be located at the very
extreme of the parameter space, or even 'beyond that' ? Example to
express it and my very nontechnical 'beyond that': The von Mises
distribution is a circular
2011 Jun 22
1
caret's Kappa for categorical resampling
Hello,
When evaluating different learning methods for a categorization problem with
the (really useful!) caret package, I'm getting confusing results from the
Kappa computation. The data is about 20,000 rows and a few dozen columns,
and the categories are quite asymmetrical, 4.1% in one category and 95.9% in
the other. When I train a ctree model as:
model <- train(dat.dts,
2012 Oct 16
4
how to extract from list
Hi all,
I have a list of 20000 data, and the list look like below. I wonder what is
the simplest way to extract 'kappa' value (or 'xi' or 'alpha' for the
matter) from each of the data. How can I simply code it without having to
change the list to a dataframe first? Many thanks!
$X19997
xi alpha kappa
784.7718640 165.4065141 -0.2709599
$X19998
2006 Apr 28
1
Where do I find Cohen´s kappa???
Hello,
I?m looking for a way to measure the goodness of fit of my model with Cohen?s Kappa (scaling between 0 and 1).
The kappa function does not give the results I?m looking for. Heres the code:
z<-glm(x~y,binomial)
kappa(z, exact = T)
Does anyone know more?
many thanks
Christian
--
_______________________________________________
Search for businesses by name, location, or phone number.
2003 Jul 18
3
question about formulating a nls optimization
Dear list,
I'm migrating a project from Matlab to R, and I'm
facing a relatively complicated problem for nls. My
objective function is below:
>> objFun <- function(yEx,xEx,tEx,gamma,theta,kappa){
yTh <- pdfDY(xEx,tEx,gamma,theta,kappa)
sum(log(yEx/yTh)^2)
}
The equation is yTh=P(xEx,tEx) + noise.
I collect my data in:
>> data <-
2012 Feb 10
4
function arrows.circular not working
I have started using the circular package but it is not recognizing the function arrows.circular. I attempted to use the example provided in the circular manual. Here is the example code using the circular package:
plot(rvonmises(10, circular(0), kappa=1))
arrows.circular(rvonmises(10, circular(0), kappa=1))
arrows.circular(rvonmises(10, circular(0), kappa=1), y=runif(10), col=2)
2009 Jul 13
3
Help With Fleiss Kappa
Hi All,
I am using fleiss kappa for inter rater agreement. Are there any know
issues with Fleiss kappa calculation in R? Even when I supply mock data
with total agreement among the raters I do not get a kappa value of 1.
instead I am getting negative values.
I am using the irr package version 0.70
Any help is much appreciated.
Thanks and Regards
M
[[alternative HTML version deleted]]
2006 Dec 11
1
cohen kappa for two-way table
Greetings,
I am a bit confused by the results returned by the functions:
cohen.kappa {concord}
classAgreement {e1071}
when using a two-way table.
for example, if I have an matrix A, and a similar matrix B (same
dimensions), then:
matrix A and B can be found:
http://casoilresource.lawr.ucdavis.edu/drupal/files/a_40.txt
http://casoilresource.lawr.ucdavis.edu/drupal/files/b_40.txt
A <-
2008 Sep 07
1
cohen's kappa
Dear all,
I have a question on Cohen's kappa:
Assume I have two datasets, one has 500 objects, 10 methods and the other,
1000 different objects, 20 different methods. Could I compare between the
two datasets to conclude the 10 methods are more "concordant" than the 20
ones by looking at some output, for example, cohen.kappa{concord} ?
One more, could anyone explain in brief,
2003 Aug 20
2
Method of L-BFGS-B of optim evaluate function outside of box constraints
Hi, R guys:
I'm using L-BFGS-B method of optim for minimization problem. My function
called besselI function which need non-negative parameter and the besselI
will overflow if the parameter is too large. So I set the constraint box
which is reasonable for my problem. But the point outside the box was
test, and I got error. My program and the error follows. This program
depends on CircStats
2010 Jan 02
2
ifelse and piecewise function
I am a novice user of "R" and I'm learning with R version 2.8.1, using
WinEdt_1.8.1, under Widows Vista Home Version.
## The test function below, from a vector input, returns vector values:
# and it contains an "ifelse"statement
TEST<- function(x) {
low<- -x^2
up<- x^4
ifelse(x>=0,up,low )
}
u<- seq(-1,1,0.5)
TEST(u)
2006 Oct 02
2
R function to compute kappa statistics for two vector
Dear R-user,
Did anybody know how to calculate the kappa statistics of two vectors for
the agreement? for example:
a<-c(0,1,0,0,1,0)
b<-c(0,1,1,0,0,1)
I know the percent of agreement is 3/6, but how to get the kappa?
[[alternative HTML version deleted]]
2011 Jun 18
2
different results from nls in 2.10.1 and 2.11.1
Hi,
I've noticed I get different results fitting a function to some data on
my laptop to when I do it on my computer at work.
Here's a code snippet of what I do:
##------------------------------------------------------------------
require(circular) ## for Bessel function I.0
## Data:
dd <- c(0.9975948929787, 0.9093316197395, 0.7838819026947,
0.9096108675003, 0.8901804089546,
2002 Jul 18
1
problem with substitute
Hello, I have a data base with variables pasthma,kasthma,sex,etc.
I wrote a program to compute the Kappa statistic between pasthma and
kasthma.
Actually "did the child had asthma" answered by the parents and by the
child.
kappa <- function(x) {
r <- paste("p",evaluate(x),sep="")
c <- paste("k",evaluate(x),sep="")
a <- table(r,c)
...
2008 Jun 12
2
arima() bug
I guess this is more r-devel than r-help.
Note, I am just the messenger - I have no idea what the user is trying to model here.
arima() crashes R (segfault) with Linux R-2.7.0, Solaris R-2.6.0:
*** caught segfault ***
address 42400000, cause 'memory not mapped'
Traceback:
1: .Call(R_getQ0, phi, theta)
2: makeARIMA(trarma[[1]], trarma[[2]], Delta, kappa)
3: arima(x, c(1, 0, 1), c(1,