Displaying 20 results from an estimated 700 matches similar to: "Error in mvpart example"
2006 Mar 08
1
function gdist, dist and vegdist in mvpart
Dear R community,
I am analyzing plant communities with the function mvpart, using a
dissimilarit matrix as input. The matrix is calculated with the funtion
gdist.
fit <- mvpart(gdist (ba12[,18:29], meth="maximum", full=TRUE,
sq=F) ~ beers + slope_dem + elev_dem+ plc_dem + pr_curv+
+curv+max_depth+doc_rocks+ abandon+land_use+ca_old,
data=ba12, xv="p")
This
2010 Aug 13
3
Delete rpart/mvpart cross-validation output
Dear all,
I was wondering if there is a simple way to avoid printing the multiple
cross-validation automatic output to the console of recursive partitionning
functions like rpart or mvpart. For example...
> data(spider)
>
mvpart(data.matrix(spider[,1:12])~herbs+reft+moss+sand+twigs+water,spider,xv="1se",xvmult=100)
*X-Val rep : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
2004 Nov 09
1
gdist and gower distance
Dear All,
I would like to ask clarifications on the gower distnce matrix calculated by the function gdistin the library mvpart.
Here is a dummy example:
> library(mvpart)
Loading required package: survival
Loading required package: splines
mvpart package loaded: extends rpart to include
multivariate and distance-based partitioning
> x=matrix(1:6, byrow=T, ncol=2)
> x
[,1]
2012 Nov 08
2
Comparing nonlinear, non-nested models
Dear R users,
Could somebody please help me to find a way of comparing nonlinear, non-nested
models in R, where the number of parameters is not necessarily different? Here
is a sample (growth rates, y, as a function of internal substrate
concentration, x):
x <- c(0.52, 1.21, 1.45, 1.64, 1.89, 2.14, 2.47, 3.20, 4.47, 5.31, 6.48)
y <- c(0.00, 0.35, 0.41, 0.49, 0.58, 0.61, 0.71, 0.83, 0.98,
2011 Sep 12
1
coxreg vs coxph: time-dependent treatment
Dear List,
After including cluster() option the coxreg (from eha package)
produces results slightly different than that of coxph (from survival)
in the following time-dependent treatment effect calculation (example
is used just to make the point). Will appreciate any explaination /
comment.
cheers,
Ehsan
############################
require(survival)
require(eha)
data(heart)
# create weights
2012 Apr 23
1
change color scheme in mvpart
Hello everyone, I am currently using the mvpart package and would like to change the color scheme it uses, and was hoping someone could help me out. All of the papers I have found have used a grayscale but I can't seem to figure out how they did that! Currently, mvpart plots barplots in a repeating sequence of 3 shades of blue. So if you have 6 response variables the same shade of blue is used
2009 Mar 23
1
mvpart error
Hello all,
When attempting a classification tree using mvpart, I get the following
error:
> thesis2.mvp=mvpart(bat_sp~., data=alltrees.df)
Error in all(keep) :
unused argument(s) (c(TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE,
2011 Sep 13
1
mvpart analyses with covariables
Hi all,
I am fairly new to R and I am trying to run mvpart and create a MRT using
explanatory variables and covariables. I've been following the procedures in
Numerical Ecoogy with R.
The command (no covariables) which works fine -
ABUNDTMRT <- mvpart(abundance ~
.,factors,margin=0.08,cp=0,xv="1se",xval=nrow(abundance),xvmult=100,which=4)
where abundance is 4th root
2005 Jun 15
1
anova.lme error
Hi,
I am working with R version 2.1.0, and I seem to have run into what looks
like a bug. I get the same error message when I run R on Windows as well as
when I run it on Linux.
When I call anova to do a LR test from inside a function, I get an error.
The same call works outside of a function. It appears to not find the right
environment when called from inside a function. I have provided
2008 Feb 29
1
controlling for number of elements in each node of the tree in mvpart
Still about the mvpart.
Is there any way I can control for the number of elements in each node
in the function mvpart? Specifically, how can I ask partition to
ignore node with elements less than 10?
Thanks!
-Shu
2005 Aug 08
2
INDVAL and mvpart
Hi,
I'd like to perform Dufrene-Legendre Indicator Species Analysis for
a multivariate regression tree. However I have problems with arguments
of duleg(veg,class,numitr=1000)function. How to obtain a vector of
numeric class memberships for samples, or a classification object
returned from mvpart?
thanks in advance
--
Best regards,
Agnieszka Strzelczak
2006 Dec 28
3
CV by rpart/mvpart
Dear R-list,
I am using the rpart/mvpart-package for selecting a right-sized regression tree by 10-fold cross-validation. My question: Is there a possibility to find out for every observation in which of the ten folds it is lying? I want to use the same folds for validating another regression method (moving averages) in order to choose the better one.
Thanks a lot,
Pedro
2008 Feb 29
1
barplot and pca plot in mvpart/rpart
Hello,
I'm using the R package called mvpart, which is about the multivariate
regression trees.
The function I wrote is:
mrt1<- mvpart(coefmat~sChip+sScreen+sMem,data=mixdata, xv="pick",
plot.add=TRUE,uniform=TRUE,which=4,all=TRUE,xadj=2,yadj=2,rsq=TRUE,big.pts=TRUE,wgt.ave.pca=TRUE,legend=TRUE,bars=F,
pca=TRUE)
where "coefmat" is a matrix(of dimension N*K) to store
2010 Mar 12
1
using xval in mvpart to specify cross validation groups
Dear R's
I'm trying to use specific rather than random cross-validation groups
in mvpart.
The man page says:
xval Number of cross-validations or vector defining cross-validation groups.
And I found this reply to the list by Terry Therneau from 2006
The rpart function allows one to give the cross-validation groups explicitly.
So if the number of observations was 10, you could use
2008 Apr 17
1
survreg() with frailty
Dear R-users,
I have noticed small discrepencies in the reported estimate of the
variance of the frailty by the print method for survreg() and the
'theta' component included in the object fit:
# Examples in R-2.6.2 for Windows
library(survival) # version 2.34-1 (2008-03-31)
# discrepancy
fit1 <- survreg(Surv(time, status) ~ rx + frailty(litter), rats)
fit1
fit1$history[[1]]$theta
2010 Apr 26
1
mvpart : Printing response values at terminal nodes
I have created a multivariate regression tree using mvpart, with 3-4
responses. Though the plot shows bargraphs for each response, I would
like to have the VALUES of the responses
printed or indicated (via a scale or something) alongside the bargraph.
Is this possible ??
Thanks,
Manjunath
[[alternative HTML version deleted]]
2004 Dec 20
2
problems with limma
I try to send this message To Gordon Smyth at smyth at vehi,edu.au but it bounced
back, so here it is to r-help
I am trying to use limma, just downloaded it from CRAN. I use R 2.0.1 on Win XP
see the following:
> library(RODBC)
> chan1 <- odbcConnectExcel("D:/Data/mgc/Chips/Chips4.xls")
> dd <- sqlFetch(chan1,"Raw") # all data 12000
> #
> nzw <-
2006 Aug 13
1
Gower Similarity Coefficient
I'm interested in clustering my data using the Gower Similarity Coefficient,
and I was wondering if R is capable of using that metric
Timothy Rye
[[alternative HTML version deleted]]
2011 Jan 21
2
Looping with incremented object name and increment function
Folks,
I am trying to get a loop to run which increments the object name as part of
the loop. Here "fit1" "fit2" "fit3" and "fit4" are linear regression models
that I have created.
> for (ii in c(1:4)){
+ SSE[ii]=rbind(anova(fit[ii])$"Sum Sq")
+ dfe[ii]=rbind(summary(fit[ii])$df)
+ }
Error in anova(fit[ii]) : object 'fit' not found
2005 Feb 14
1
testing equality of variances across groups in lme?
Hello. I am fitting a two-level mixed model which assumes equality of
variance in the lowest-level residuals across groups. The call is:
fit3<-lme(CLnNAR~CLnRGR,data=meta.analysis,
+ na.action="na.omit",random=~1+CLnRGR|study.code)
I want to test the assumption of equality of variances across groups at
the lowest level. Can someone tell me how to do this? I know that one