Displaying 20 results from an estimated 1000 matches similar to: "R code Error : Hybrid Censored Weibull Distribution"
2005 Apr 29
2
Subarrays
Define an array
> v<-1:256
> dim(v)<-rep(4,4)
Subarrays can be obtained as follows:
> v[3,2,,2]
[1] 71 87 103 119
> v[3,,,2]
[,1] [,2] [,3] [,4]
[1,] 67 83 99 115
[2,] 71 87 103 119
[3,] 75 91 107 123
[4,] 79 95 111 127
In the general case this procedure is very tedious.
Given an array
A, dim(A)=(dim_1,dim_2,...,dim_d)
and two vectors
2013 Jan 28
2
R plot like candlestick
Hi all,
I'm new on this list so I greet all.
My question is: does exist in R a plot similar to candlestick plot but
not based on xts (time series)? I have to plot a range of 4 value: for
every item I have min value, max value and 2 intermediate values. I
would like plot this like a candlestick, i.e. with a box between 2
intermediate values and 1 segment between box and min value and a
segment
2010 Mar 23
1
Changing content of column in data.frame + efficient join extraction between 2 data.frames
Dear R users,
I have 2 SpatialPointsDataFrame's, pcs and East.
The column str_1 in the first (pcs) is:
> pcs[0:4,]
coordinates cat str_1 int_1 int_2 dbl_1 dbl_2
1 (101000, 263000) 1 "SM06B" 101000 263000 4.978915 -4.293668
2 (101000, 265000) 2 "SM06C" 101000 265000 4.960478 -4.266742
3 (101000, 267000) 3 "SM06D" 101000 267000
2003 Jun 26
3
degrees of freedom in a LME model
Dear All,
I am analysing some data for a colleague (not my data, gotta be published
so I cannot divulge).
My response variable is the number of matings observed per day for some
fruitlies.
My factors are:
Day: the observations were taken on 9 days
Regime: 3 selection regimes
Line: 3 replicates per selection regime.
I have 81 observations in total
The lines are coded A to I, so I do not need
2010 Mar 16
0
recursive term
Hi r-users;
I have this values:
eign_val <- c(137.810447,3.538721,2.995161,1.685670)
alp <- 1.6549 ; lamda <- eign_val
lamda_m <- min(lamda)
First I calculated manually:
delta0 <- 1
delta1 <- alp*delta0*(4-lamda_m*(1/lamda[1]+1/lamda[2]+1/lamda[3]+1/lamda[4]))
delta1
delta2 <- (alp/2)*(delta1*(delta1/alp) + delta0*((1-lamda_m/lamda[1])^2+
2010 Feb 09
1
lm combined with splines
Hello,
In the following I tried 3 versions of an example in R help. Only the two first predict command work.
After :
library(splines)
require(stats)
1)
fm1 <- lm(weight ~ bs(height, df = 5), data = women)
ht1 <- seq(57, 73, len = 200)
ph1 <- predict(fm1, data.frame(height=ht1)) # OK
plot(women, xlab = "Height (in)", ylab = "Weight (lb)")
lines(ht1, ph1)
2)
2001 Jul 02
1
nls newbie: help approximating Weibull distribution
Hi folks,
I tried to retain the Weibull distribution using the `nls' function
and proceeding along the lines of the example provided in the
`SSweibull' help (at least I thought so):
t <- (1:200)/100
v <- pweibull(t, shape=3, scale=1)
df <- data.frame(Time=t, Value=v)
Asym <- 1.0; Drop <- 1.0; lrc <- 0; pwr <- 1
df.estimate <- nls(Value ~ SSweibull(Time,
2005 Sep 26
2
nls and na/Nan/Inf error
I am trying to it a particular nonlinear model common in Soil Science to
moisture release data from soil. I have written the function as shown
below according to the logist example in Ch8 of Pinheiro & Bates. I am
getting the following error (R version 2.1.1)
*Error in qr(attr(rhs, "gradient")) : NA/NaN/Inf in foreign function
call (arg 1)*
Below is the function and data.
/#
2015 Sep 10
3
[OpenCL] Implicit arithmetic conversion of INT_MIN to int vector type
Hello,
I recently came across an OpenCL kernel in which an int vector type was subtracted from the INT_MIN constant, e.g.
int2 v2 = INT_MIN - (int2)(0);
INT_MIN was defined as
#define INT_MIN (-2147483648)
Clang in OpenCL modes (-x cl) produces the following error:
vector_conversion.c:12:42: error: can't convert between vector values of different size ('long' and 'int2'
2009 Jul 30
1
lmer() and "$ operator is invalid for atomic vectors"
Hi all,
I am a bit mystified by this error message that I get when I try to apply
lmer() to a simple dataset with one between factor (age) and one within
factor (item): "$ operator is invalid for atomic vectors"
I'll just provide the code, because I don't see where the problem is:
library(lme4)
options(contrasts=c("contr.helmert","contr.poly"))
data =
2009 Apr 24
1
the puzzle of eigenvector and eigenvalue
Dear all
I am so glad the R can provide the efficient calculate about
eigenvector and eigenvalue.
However, i have some puzzle about the procedure of eigen.
Fristly, what kind of procedue does the R utilize such that the eigen
are obtained?
For example, A=matrix(c(1,2,4,3),2,2)
we can define the eigenvalue lamda, such as
det | 1-lamda 4 | =0
| 2 3-lamda |
then
2008 Feb 08
2
Catching NaNs from pweibull()
Hello,
I am working with the nls() function and inserting a formula into it that
uses the pweibull function. However the pweibull function is annoyingly
producing NaNs, which nls() refuses to handle. I have put a sample of the
code below. Is there a way to prevent these NaNs from interfering, for
example a method to catch them? I get the following error when I try to run
the code:
res.nls <-
2011 Apr 19
1
How to get the tuning parameter lamda in storey's qvalue package
Dear All,
In Storey's estimator of the proportion of true nulls, the estimator depends on the tuning parameter lamda.
Suppose now that an estimator of this proportion has been obtained by the qvalue package, what is the lamda that
corresponds to the estimate? How to get this lamda?
Thanks,
-Chee
[[alternative HTML version deleted]]
2000 Mar 01
2
Help please..
Hello R-world,
I am facing a peculiar problem and hope someone out there
can comment on it.
In goodness-of-fit tests for evaluation of distributions,
there are three well-known methods:
1. Chi-square
2. Anderson-Darling
3. Kolmogorov-Sminrov
I am trying to use the second test. Many researchers have
reported results using this test. I wrote programs in C and
now in R to do this. I run into
2013 Mar 03
1
distribution functions and lists
Hello everyone,
I have a quick question but I am stuck with it and I do not know how to solve it.
Imagine I need the distribution function of a Weibull(1,1) at t=3, then I will write pweibull(3,1,1).
I want to keep the shape and scale parameters in a list (or a vector or whatever). Then I have
parameters<-list(shape=1,scale=1)
but when I write pweibull(3,parameters) I get the following
2009 Feb 12
2
[LLVMdev] Eliminate PHI for non-copyable registers
Chris Lattner-2 wrote:
>
>
> On Feb 11, 2009, at 4:07 AM, Alex wrote:
>
>> In my hardware there are two special registers cannot be copied but
>> can only be assigned and referenced (read) in the other instruction.
>> They are allocatable also.
>>
>> br i1 %if_cond, label %then, label %else
>> then:
>> %x1 = fptosi float %y1 to i32
2002 May 12
2
Is this a bug of pweibull()? (Follow up)
Please allow me to add just a little more about this:
nothing wrong with pweibull(), namely, the two cases I reported:
pweibull(3:10, 2) and pweibull(3:10, 2.1),
in rw1041 and earlier version.
I wonder this might just due to the change from rw1041 to rw1050,
however, I can't find anything relevant (seems to me) in the News
or Readme.
Thanks Sundar for the suggestion of using 1 -
2013 Mar 11
1
Implementation of the PL2 weighting scheme of the DFR Framework
Hello guys.I am working on implementing the PL2 weighting scheme of the DFR
framework by Gianni Amati.
It uses the Poisson approximation of the Binomial as the probabilistic
model (P), the Laplace law of succession to calculate the after effect of
sampling or the risk gain (L) and within document frequency normalization
H2(2) (as proposed by Amati in his PHD thesis).
The formula for w(t,d) in
2003 May 04
0
R-1.7.0 build feedback: NetBSD 1.6 (PR#2837): final report
I've now done two rebuilds of R-1.7.0 on NetBSD 1.6, one with the
--without-zlib configure option, and one without. Both builds use the
recently-installed gcc-3.2.3 compiler.
As before, the one built normally gets a segment violation, whereas
the one built with the --without-zlib option works.
The odd thing is that neither uses shared libraries for zlib:
% ldd /usr/local/lib/R/bin/R.bin
2008 Dec 18
1
Indicator function for merged times (was: Re: Rr: For and if confusion)
Please start a new thread for a new topic and use a
meaningful subject for sake of the archives and
everyone trying to follow.
Using your Int1, correcting your Int2 and using your
Y (which goes to Jul not Aug as per the comment):
library(zoo)
> as.ts(with(merge.zoo(Int1, Int2, Y, fill = 0), pmax(Int1, Int2)))
Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec
1992