Displaying 10 results from an estimated 10 matches for "resamps".
2013 Feb 07
4
Sourcing my file does not print command outputs
I looked at the documentation of source() and summary(), and I could not
find the reason why calling something like:
> summary(resamps)
from the command line, works (it prints the summary)
whereas calling
summary(resampls)
from a file that I source with source("my_file.r") does not print anything.
How can I get summary(resamps) to print when I source a file with this
command?
Thanks,
James
[[alternative HTML ver...
2013 Feb 07
0
FW: Sourcing my file does not print command outputs
...;- train(X,Y,method='rf',trControl=myCtrl,tuneLength=1)
NNmodel <- train(X,Y,method='nnet',trControl=myCtrl,tuneLength=3, trace = FALSE)
## GLMnet = GLMmodel,
...
#Assess re-sampled (out of sample) accuracy
print("Assessing re-sampled (OOB) accuracy")
resamps <- resamples(
list( RF = RFmodel,
NN = NNmodel
))
print("Summarizing resamps")
summary(resamps)
dotplot(resamps, metric = "Accuracy")
========================================
Thanks,
James
On Thu, Feb 7, 2013 at 4:37 PM, Nordlund,...
2008 Dec 12
0
Help with a permutation test
Hello List and thanks in advance for all of your help,
I am trying implement a permutation test of a multinomial logistic
regression ('multinom' within the nnet package). In the end I want to
compare the parameter estimate from my data to the distribution of
randomized parameter estimates.
I have figured out how to permute my dependent variable (MNNUM) x number of
times, apply
2013 Feb 07
1
Saving model and other objects from caret
Say I train a model in caret, e.g.:
RFmodel <- train(X,Y,method='rf',trControl=myCtrl,tuneLength=1)
How can I save this to disk and load it later in R?
How about an object of the class "resamples"?
resamps <- resamples(
list( RF = RFmodel,
SVM = SVMmodel,
KNN = KNNmodel,
NN = NNmodel
))
Thanks,
James
[[alternative HTML version deleted]]
2013 Apr 23
1
lmer with only random effect
Dear all,
I want to fit a random effect model with only one random factor. I do not
want to
include the intercept term either.
The model I using now is
lmer(values ~ (1|lot), data=tmp)
The results are as below. How do I take out the intercept term? Or
if this is not possible for the lmer function, is it possible using lme
function in the "nlme" package?
Thank you very much in
2011 Jun 23
2
Confidence interval from resampling
Dear R gurus,
I have the following code, but I still not know how to estimate and extract
confidence intervals (95%CI) from resampling.
Thanks!
~Adriana
#data
penta<-c(770,729,640,486,450,410,400,340,306,283,278,260,253,242,240,229,201,198,190,186,180,170,168,151,150,148,147,125,117,110,107,104,85,83,80,74,70,66,54,46,45,43,40,38,10)
x<-log(penta+1)
plot(ecdf(x),
2012 Jan 04
3
informal conventions/checklist for new predictive modeling packages
Working on the caret package has exposed me to the wide variety of
approaches that different authors have taken to creating predictive
modeling functions (aka machine learning)(aka pattern recognition).
I suspect that many package authors are neophyte R users and are
stumbling through the process of writing their first R package (or R
code). As such, they may not have been exposed to some of the
2008 May 31
0
FFT Resampler spectrograms
Using the following MATLAB snippet:
fnames={'chirp','perfect','block','filter'}
for k=1:length(fnames)
fn=fnames{k};
myfile=fopen([fn, '.fl'], 'r', 'ieee-le');
x=fread(myfile, Inf, 'float32', 0, 'ieee-le');
fclose(myfile);
X=specgram(x,2048,1,kaiser(2048,14));
spectrogram_floor=-96;
2011 May 01
0
Dummy variables using rfe in caret for variable selection
I'm trying to run "rfe" for variable selection in the caret package, and am
getting an error. My data frame includes a dummy variable with 3 levels.
x <- chlDescr
y <- chl
#crate dummy variable
levels(x$State) <- c("AL","GA","FL")
dummy <- model.matrix(~State,x)
z <- cbind(dummy, x)
#remove State category variable
w <- z[,c(-4)]
2012 Sep 26
3
Reading multiple files
Hi,
I have 35 data files for reading. I would like get a program for
performing reading of 35 files at once.
All are of the type: Dados1.raw, Dados2.raw and so on.
If the files have the same number of columns, I can read with the
following commands:
rm(list=ls())
filenames = list.files(path="~/Silvano/Arq", pattern="Dados+.*raw")
names = substr(filenames, 1, 7)
for(i in