Re: [R] How to export/save an mrpp object?

2011-01-07 Thread Nikos Alexandris
Nikos: I finally ran mrpp tests. I think all is fine but one very important issue: I have no idea how to export/save an mrpp object. Tried anything I know and searched the archives but found nothing. David W: And what happened when you tried what seems like the obvious:

Re: [R] How to export/save an mrpp object?

2011-01-07 Thread Nikos Alexandris
Gavin: [...] I think you should read ?load to rethink what these functions do and how they do it. [...] Absolutely correct. I will. Thank you for your time Gavin, Nikos __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help

[R] How to export/save an mrpp object?

2011-01-06 Thread Nikos Alexandris
Greets (again) :-) I finally ran mrpp tests. I think all is fine but one very important issue: I have no idea how to export/save an mrpp object. Tried anything I know and searched the archives but found nothing. Any ideas? Is really copy-pasting the mrpp results the only way? Thank you for

Re: [R] Estimate between-axes vs within-axes heterogeneity of multivariate matrices

2010-12-22 Thread Nikos Alexandris
On Wednesday 22 of December 2010 05:57:17 Nikos Alexandris wrote: [...] Apologies for repeating the same question (trying to understand the problem myself). I started to get a grip on this. But anyway, my questions are actually not directly about R questions - sorry for the traffic

Re: [R] Estimate between-axes vs within-axes heterogeneity of multivariate matrices

2010-12-22 Thread Nikos Alexandris
This time with a more-R oriented question: Is the mrpp {vegan} package [1] useful in trying to check, or get a clue about the differences between- and within-axes (or variables or dimensions or columns) of a multivariate matrix? The description explains: ...(MRPP) provides a test of whether

[R] Estimate between-axes vs within-axes heterogeneity of multivariate matrices

2010-12-21 Thread Nikos Alexandris
Hi! My question(s) in the end might be silly but I am no expert on this, so here it goes: Noy-Meir (1973), Pielou (1984) and a few others have pointed to non-centered PCA being in some cases useful. They clearly explain that it is the case when multi-dimensional data display distinct clusters

[R] Estimate between-axes vs within-axes heterogeneity of multivariate matrices

2010-12-21 Thread Nikos Alexandris
Hi! My question(s) in the end might be silly but I am no expert on this, so here it goes: Noy-Meir (1973), Pielou (1984) and a few others have pointed to non-centered PCA being in some cases useful. They clearly explain that it is the case when multi-dimensional data display distinct clusters

Re: [R] Factor Loadings in Vegan's PCA

2010-06-30 Thread Nikos Alexandris
On Wednesday 30 of June 2010 23:02:09 afso...@unisinos.br wrote: Hi all, I am using the vegan package to run a prcincipal components analysis on forest structural variables (tree density, basal area, average height, regeneration density) in R. However, I could not find out how to

Re: [R] Note on PCA (not directly with R)

2010-06-30 Thread Nikos Alexandris
Christofer Bogaso wrote: Dear all, I am looking for some interactive study materials on Principal component analysis. Basically I would like to know what we are actually doing with PCA? Having in mind the eigenvalue decomposition and a bivariate data set, the sum- it-all in a few sentences I

Re: [R] Attempt to customise the plotpc() function

2010-05-16 Thread Nikos Alexandris
Nikos Alexandris: Among the (R-)tools, I've seen on the net, for (bivariate) Principal Component scatter plots (+histograms), plotpc [1] is the one I like most. [...] I started the modification by attempting first to get a prcomp version of plotpc() (named it plotpc.svd()) by altering

Re: [R] Attempt to customise the plotpc() function

2010-05-16 Thread Nikos Alexandris
Peter Ehlers wrote: Nikos, I think you can just replace the line pc - princomp(x[,1:2], scores=TRUE, na.action=na.fail) with pc - prcomp(x[,1:2], retx=TRUE, center=pc.center, scale.=pc.scale, na.action=na.fail) and rename the components of pc

Re: [R] Attempt to customise the plotpc() function

2010-05-16 Thread Nikos Alexandris
Peter Ehlers wrote: and then use the rest of the plotpc() code as is (except for maybe having to use flip1=TRUE, etc). Nikos: Hmm... I am _now_ working on it to understand how I could make this automatic!. If I give flip1, flip2 (=TRUE) the histograms are located where they should

[R] Attempt to customise the plotpc() function

2010-05-15 Thread Nikos Alexandris
Dear R-list, Among the (R-)tools, I've seen on the net, for (bivariate) Principal Component scatter plots (+histograms), plotpc [1] is the one I like most. By default it performs PCA on a bivariate dataset based on R's princomp() (which is the eigenvector-based algebraic solution to PCA). I

Re: [R] Attempt to customise the plotpc() function

2010-05-15 Thread Nikos Alexandris
On Saturday 15 of May 2010 19:09:30 Nikos Alexandris wrote: Among the (R-)tools, I've seen on the net, for (bivariate) Principal Component scatter plots (+histograms), plotpc [1] is the one I like most. [...] [1] http://cran.r-project.org/web/packages/plotpc/index.html

Re: [R] Cross-checking a custom function for separability indices

2010-05-04 Thread Nikos Alexandris
data.frames with identical structure # by Nikos Alexandris, Freiburg, April 2010 # Code -- separability.measures.class - function ( Data.Frame.1

[R] Cross-checking a custom function for separability indices

2010-04-21 Thread Nikos Alexandris
# --- Code --- # Custom function for various Separability Measures # by Nikos Alexandris, Freiburg, 8.04.2010 # ( based on Divergence and Jeffries-Matusita, requires input variables as.matrices ) separability.measures - function

Re: [R] c(), or cat(), or paste(), all cause unwanted reordering

2010-04-06 Thread Nikos Alexandris
On Thu, 2010-03-25 at 11:54 -0800, Jeff Brown wrote: Wow, you guys are awesome. Thanks! Thanks for the cat() question Jeff and to all guRus out there for the replies. This is something I was looking for the last hour. Nikos __ R-help@r-project.org

Re: [R] c(), or cat(), or paste(), all cause unwanted reordering

2010-04-06 Thread Nikos Alexandris
Jeff Brown wrote: Wow, you guys are awesome. Thanks! Nikos Alexandris wrote: Thanks for the cat() question Jeff and to all guRus out there for the replies. This is something I was looking for the last hour. I can't seem to make this run: I have a function ( Column.of.Matrix.1

Re: [R] c(), or cat(), or paste(), all cause unwanted reordering

2010-04-06 Thread Nikos Alexandris
On Tue, 2010-04-06 at 19:29 +0200, Nikos Alexandris wrote: Jeff Brown wrote: Wow, you guys are awesome. Thanks! Nikos Alexandris wrote: Thanks for the cat() question Jeff and to all guRus out there for the replies. This is something I was looking for the last hour. I can't seem

Re: [R] Define column names to a series of data.frames

2010-03-19 Thread Nikos Alexandris
Nikos Alexandris wrote: ... I have 6 data frames consisting of 6 rows x 7 columns put together from other data.frames. ... I want to give the following column names to each data.frame: (SDev, PC1, PC2, PC3, PC4, PC5, PC6) ... How is it to be done at once for all data.frames

Re: [R] Odp: Define column names to a series of data.frames

2010-03-12 Thread Nikos Alexandris
Thanks to all for the replies. I'll post back here when I get things working (...in a couple of days). Nikos __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide

[R] Define column names to a series of data.frames

2010-03-11 Thread Nikos Alexandris
Greets to the list! I am aware that this topic has been discussed several times. And I've read quite some related posts [1]. Yet, can't seem to give a solution to my problem. I have 6 data frames consisting of 6 rows x 7 columns put together from other data.frames. Something like: a b c d e

Re: [R] Best R text editors?

2009-09-11 Thread Nikos Alexandris
[Answering to the threads question] For those who use Gnome's gedit, there is now RGedit: http://sourceforge.net/projects/rgedit Apologies if this was already posted, Nikos __ R-help@r-project.org mailing list

Re: [R] labeling in qplot

2009-08-05 Thread Nikos Alexandris
On Tue, 2009-08-04 at 20:16 -0700, Mohan S wrote: HI am plotting different density plots in one graph each with a different color. And i want to add labels to plot mentioning which color belongs to which data series. p2 - qplot(corArms, data = data1, geom = density, adjust=0.4,

Re: [R] why is 0 not an integer?

2009-08-05 Thread Nikos Alexandris
On Wed, 2009-08-05 at 13:16 -0700, Steve Jaffe wrote: Why when I assign 0 to an element of an integer vector does the type change to numeric? Here is a particularly perplexing example: v - 0:10 v [1] 0 1 2 3 4 5 6 7 8 9 10 class(v) [1] integer v[1] - 0 try this: v -

Re: [R] productivity tools in R?

2009-07-02 Thread Nikos Alexandris
On Thu, 2009-07-02 at 00:01 -0500, Gene Leynes wrote: playwith(xyplot(z3), time.mode = TRUE) WoW! Looks (and is) GrEaT! Nikos __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide

Re: [R] Help on creating a sequence of vectors

2009-06-22 Thread Nikos Alexandris
megh: I want to create a number of vectors like : vec1 - rnorm(1) vec2 - rnorm(2) vec3 - rnorm(3) and so on... Maybe try the assign() function. Something like: for (i in 1:10) assign ( paste ( vec , i , sep = ) , rnorm(i) ) Kind regards, Nikos

[R] How to plot hyperbolic iso-lines of a cost function?

2009-06-12 Thread Nikos Alexandris
Hi R-specialists! I would like to draw some hyperbolic (iso-)lines of a cost function in a bi-dimensional space ( =shapes of a cost function ), based on (the general form): C(x) = c1*Ce + c2*Oe + c3*{ 1 - [ (1 - Ce)^a * (1 - Oe)^b ] } where: - Oe/Ce are Omission/Commission (ranging between 0

Re: [R] GRASS raster data processing

2009-06-11 Thread Nikos Alexandris
Maayt: I just imported two raster maps into R using the SPGRASS6 package, one containing elevation data and the other containing an erosion index: Kar_inc -readRAST6(Incis_Kar, plugin=FALSE) Kar_dem - readRAST6(DEM_Kar, plugin=FALSE) I just wanted to make a xy plot of erosion parameter vs

[R] create vectors within a double loop

2009-05-23 Thread Nikos Alexandris
Hi R-list. This is my first post. I'll try to be as precise as possible with the difficulty I have to get things done. I have a hard time trying to construct a double for loop and create within the inner loop new objects (in this case vectors). I posted this question in a non-directly related

Re: [R] create vectors within a double loop

2009-05-23 Thread Nikos Alexandris
jim holtman: You might want to look at how to use 'lapply' to create lists. Here is one way of doing it: # create test data a_threshold - b_threshold - as.data.frame(matrix(sample(c(1:5, NA), 100, TRUE), 10)) classification - c('a', 'b') result - lapply(classification,