similar to: 632 estimator using boot package

Displaying 20 results from an estimated 1100 matches similar to: "632 estimator using boot package"

2003 Oct 15
3
Strange scope problem
Hi, I have come across the following problem which seems to be a scoping issue but I'm at a loss to see why this is so or to find a good workaround. Suppose I have a function to get a prediction after model selection using the step function. step.pred <- function(dat, x0) { fit.model <- step(lm(y~., data=dat), trace=F) predict(fit.model, x0, se.fit=T) } This function works
2003 Oct 31
2
Summing elements in a list
Hi, Suppose that I have a list where each component is a list of two matrices. I also have a vector of weights. How can I collapse my list of lists into a single list of two matrices where each matrix in the result is the weighted sum of the corresponding matrices. I could use a loop but this is a nested calculation so I was hoping there is a more efficient way to do this. To help clarify,
2004 Apr 26
1
names attribute of data.frames after rbind
Hi, If columns of a data.frame have a names attribute and we rbind two similar data.frames together, the names of the column of the resulting data.frame only has the correct values for the first component and has "" in all other positions. Is this a documented "feature" or a bug? If it is intentional, why? Here is a small example to show what I mean. The same behaviour
2004 Jun 25
1
trouble using boot package
Hello, I am trying to carry out a bootstrap analysis (using the boot package) on a table and cannot work out how to get the results I need! I have a table ("d2") with 4 columns: "ID_code", "Age", "Quarter" and "StomWt". Age (0-5) and Quarter (1-4) are my strata Therefore I wish to estimate the confidence intervals for the mean StomWt for each Age
2005 Dec 20
2
boot problem
Hello, This is the code that is giving me problems >library(boot) >data<-read.table("test",header=FALSE,sep="\t",row.names=1) >data V2 V3 V4 A 5 8 9 B 12 54 89 C 65 89 23 D 32 69 44 E 21 84 97 F 33 59 71 G 16 45 93 H 2 46 55 I 22 33 88 >resample <- function(x,index) { sample(data,replace=TRUE) } dist<-boot(data,resample,R=1000)
2002 Aug 05
2
No subject
Hello, I downloaded R today because I was told it has very good bootstrapping abilities. What I need to do is to program it (or use an existing program) to bootstrapping test for multimodality using nonparametric kernel density estimates as proposed by Efron and Tibshirani (1993). If anyone can get me started, I will be immensely grateful. Thanks. Sangeeta
2005 Feb 23
3
bias of a boot statistic
Question: How can I get access to the bias value of a boot statistic? Details: Boot function: boot(data, statistic, R, sim="ordinary", stype="i", strata=rep(1,n), L=NULL, m=0, weights=NULL, ran.gen=function(d, p) d, mle=NULL, ...) When I create an object, containing the bootstrap statistic (object <- boot (....))I can call it and will get an output
2004 Apr 01
5
boot question
What in the world am I missing?? > x<-rnorm(20) > mean(x) [1] -0.2272851 > results<-boot(x,mean,R=5) > results[2] $t [,1] [1,] -0.2294562 [2,] -0.2294562 [3,] -0.2294562 [4,] -0.2294562 [5,] -0.2294562 Jeff Morris Ortho-Clinical Diagnostics A Johnson & Johnson Co. Rochester, NY Tel: (585) 453-5794 [[alternative HTML version deleted]]
2004 Sep 21
1
Problems with boot and optim
I am trying to bootstrap the parameters for a model that is estimated through the optim() function and find that when I make the call to boot, it runs but returns the exact same estimate for all of the bootstrap estimates. I managed to replicate the same problem using a glm() model but was able to fix it when I made a call to the variables as data frame by their exact names. But no matter how I
2005 Jun 02
2
confusion with boot
I think I am doing something wrong when I try to bootstrap R square obtained from lm. My code is included below. No matter how many times I run the simulation, I always get exactly the same result, the bias and std.error are always zero. I would think that these values should be non-zero. I would appreciate any suggestions as to what I am doing wrong, or perhaps what I fail to understand. R 2.1.0
2004 Dec 05
3
boot package
Hi, I using the boot package 1.2-20 on R 2.0.1. My statistics function estimates 6 parameters. In a small percentage of resampled data sets my statistics function doesn't produce an estimate for one parameter and the boot function stops with an error. I can write an ifelse(exists('parameter.estimate'), parameter.estimate, NA) statement within the statistic function to substitute
2003 Jun 23
1
erase.screen bug?
Hi, I'm using R 1.7.1 on a Windows 2K computer. For some reason erase.screen does not seem to be working correctly. That is it does not erase the requested screen. That is the old graphic is still visible and any subsequent graphics are superimposed over it making them impossible to read. What is worse is that they print out this way also. The same behaviour happens with a Windows XP
2004 Aug 01
1
Problem with RGui and MASS
Hi, Using R1.9.1 for Windows with Windows 2000 (also XP), I have come across the following problem that I have not seen before and am at a loss to explain. If I create an object using rlm from library(MASS) and then save the workspace, I cannot reopen it using RGUI by double clicking on the .RData file as I normally do. If I double click on the icon, R starts and then gives the following
2012 Jan 24
1
Error from Brugs "'r for windows gui front-end has stopped working''
Dear all, I just try to run the example in R brugs packages, but not only once. Loop is added in this example. After several times (7, 11, or other random number), there is an error message "r for windows gui front-end has stopped working". This happened in two laptops with windows 7 and vista. I have tried different versions of R (2.14.1 and 2.13) and Brugs packages (0.7.1 and 0.7-5).
2012 Jan 30
2
Variable selection based on both training and testing data
Dear all, The variable selection in regression is usually determined by the training data using AIC or F value, such as stepAIC. Is there some R package that can consider both the training and test dataset? For example, I have two separate training data and test data. Firstly, a regression model is obtained by using training data, and then this model is tested by using test data. This process
2003 Apr 24
1
bca ci's and NaN's in boot.out
Dear All, I am trying to use the bca.ci function on a boot.out object which consists a few NaN's and I want to ignore those NaN's, and get a ci only for the "normal" values. boot.out$t has R number of values for 3000 different statistics, so when I use boot.ci(boot.out, index=i) and i happens to be a column in boot.out$t with some NaN's in there I get an error message. I
2011 Sep 13
1
Problems of metafile plots when converting word to pdf file
Hi all, I copy metafile boxplot from R to Word. Then save as Pdf file. But I found there are some unexpected black lines in some plots within this PDF file. Please give me some advice how to get rid of these black lines in PDF files. Thanks a lot, Jim [[alternative HTML version deleted]]
2000 Mar 21
3
loading data in packages
Hi, I'm new to R and have a question which seems like it should be easy. I loaded the R port of my boot library and installed it. All of the functions and help files are available but I can't seem to access the data. The data directory was created and contains files with the extension .rda. I tried to use the data() function but I get > data(city) Error: restore file corrupted -- no
2008 Jan 25
2
Help Me to Adjust the R Code
Hi, The following code, from Angelo Canty article on line "Resampling Methods in R: the boot Package, 2002", works fine for Angelo Canty using R 2.6.0 on Windows XP. It also works for me using R 1.2.1 and S-PLUS 2000 on Windows XP after installing the S-PLUS bootstrap library, with slight differences in my outputs. > library(boot) > library(survival) >
2000 Apr 10
2
Increasing memory size in ESS
I am having a problem using ESS with R. In particular I have large data objects which exceed the 6Mb default heap memory. Outside of ESS I can run R by specifying large values of --vsize and --nsize but I can't figure out how to do this in ESS. Any help would be much appreciated. -- **************************************************** ** Angelo J. Canty **