Displaying 20 results from an estimated 1000 matches similar to: "problem wih plotrix:cluster.overplot"
2009 Feb 17
1
plot.lm: "Cook's distance" label can overplot point labels
The following code demonstrates an annoyance with plot.lm():
library(DAAGxtras)
x11(width=3.75, height=4)
nihills.lm <- lm(log(time) ~ log(dist) + log(climb), data = nihills)
plot(nihills.lm, which=5)
OR try the following
xy <- data.frame(x=c(3,1:5), y=c(-2, 1:5))
plot(lm(y ~ x, data=xy), which=5)
The "Cook's distance" text overplots the label for the point with the
2007 Jun 08
2
overplots - fixing scientific vs normal notation in output
Moving from S-plus to R I encountered many great features and a much
more stable system.
Currently, I am left with 2 problems that are handled differently:
1) I did lots of "overplots" in S-Plus using
par(new=T,xaxs='d',yaxs='d') to fix the axes
->What is the workaround in R ?
2) In S-Plus I could fix "scientific notation" or "normal notation" in
2006 Dec 03
0
overplot() examples fail (package:gplots)
require(gplots)
data(rtPCR)
overplot( RQ ~ Conc..ug.ml. | Test.Substance,
data=rtPCR,
subset=Detector=="ProbeType 7" & Conc..ug.ml. > 0,
same.scale=TRUE, log="xy", f=3/4,
main="Detector=ProbeType 7",
xlab="Concentration (ug/ml)",
ylab="Relative Gene Quantification"
)
# Error in lowess.default(mf[[-response]], mf[[response]], f = f,
2002 Feb 15
1
cmdscale k=1
In applying multidimensional scaling, it seems to me that sometimes the
underlying dimensionality of the matrix is 1. However I found a case
where cmdscale failed when I tried k=1. Here it is:
m<-matrix(
c(.5,.81,.23,.47,.61,
.19,.5,.06,.17,.28,
.77,.94,.5,.74,.85,
.53,.83,.26,.5,.64,
.39,.72,.15,.36,.5),
nrow=5)
# BTW I think cmdscale uses only the lower triangle--how to enter only
# that
2014 Nov 06
1
limit of cmdscale function
Hi
We have a few questions regarding the use of the "isoMDS" function.
When we run "isoMDS" function using 60,000 x 60,000 data matrix,
we get the following error message:
------------------------------------
cmdscale(d, k) : invalid value of 'n'
Calls: isoMDS -> cmdscale
------------------------------------
We checked the source code of "cmdscale" and
2007 Jun 14
2
Difference between prcomp and cmdscale
I'm looking for someone to explain the difference between these
procedures. The function prcomp() does principal components anaylsis,
and the function cmdscale() does classical multi-dimensional scaling
(also called principal coordinates analysis).
My confusion stems from the fact that they give very similar results:
my.d <- matrix(rnorm(50), ncol=5)
rownames(my.d) <-
2002 Dec 19
1
newbie question on dist
hi,
i have just begun using R, so please bear with me.
i am trying to use cmdscale and display the result. i read the data
using read.table(), calculate the proximity matrix using dist() and
the display the result using the cmdscale(). this is very fine.
in addition, i want the display to distinguish between two classes
of records in my data. i have my data records marked as "1" or
2004 Dec 09
1
more clustering questions
Sorry to bother you kind folks again with my questions. I am trying to
learn as much as I can about all this, and I will admit that I don't
have the proper background, but I hope that someone can at least point
me in the correct direction.
I have created a test matrix for what I want to do:
s1 s2 s3 s4 s5
s1 10 5 0 8 7
s2 5 10 0 0 5
s3 0 0 10 0 0
s4 8 0 0 10 0
s5 7
2008 Mar 13
2
Plot contour over filled contour
Dear R-users,
I haven't found a way in the searchable archive to overplot a contour
(lines) over a surface.
I have a (n,m) matrix that represents sea surface temperature that I
have plotted using image.plot(), filled.contour() or image(). I would
like to overplot this image with some contour lines of mixed layer depth
values(same size matrix). How can I do this?
Any help is appreciated,
2013 Apr 26
1
prcomp( and cmdscale( not equivalent?
Hello,
I have a dilemma that I'm hoping the R gurus will be able to help resolve.
For background:
My data is in the form of a (dis)similarity matrix created from taking the
inverse of normalized reaction times. That is, each cell of the matrix
represents how long it took to distinguish two stimuli from one another-- a
square matrix of 45X45 where the diagonal values are all zero (since this
2002 Jan 10
1
Size of type double in object type dist (PR#1255)
The following problem occurs in R 1.4.0 and 1.3.1 for Windows95,
but not in R 1.2.0 for Windows95.
The problem does not occur in R 1.4.0 for Linux PC, Linux Alpha
and HP-UX.
Sometimes, the type of 'Size' of an object of type 'dist'
changes from integer into double. Running cmdscale on such a
'dist' object gives invalid results.
I don't know what should be considered
2005 Nov 04
1
Stress in multidimensional scaling
Hello,
We are trying to find a function to compute "stress" in our
multidimensional scaling analysis of a dissimilarity matrix. We've used
"dist()" to create the matrix and "cmdscale()" for the scaling. In order
to determine the number of dimensions we would like to plot stress vs.
dimensions. However, we cannot find a pre-made command. It seems that
other
2007 Jul 23
2
cmdscale question
Hi.
I know matrices that use distances between places works fine when using
cmdscale. However, what about matricies such as:
A B C D E
A 0 1 23 12 9
B 1 0 10 12 3
C 23 10 0 23 4
D 12 12 23 0 21
E 9 3 4 21 0
i.e. matrices which do not represent physical distances between places (as
they would not make sense for real distances such as the one above)
2001 Jul 17
2
cmdscale in package mva (PR#1027)
Full_Name: Laurent Gautier
Version: 1.3.0-patched
OS: IRIX 6.5
Submission from: (NULL) (130.225.67.199)
Hello,
The function La.eigen, called by cmdscale in the package mva behaves an
unexplicable way (for me).
The following lines show what happened.
I tried the very same on linux, and it worked fine.
>a <- matrix(c(1,2,3,2),3,3)
>a
[,1] [,2] [,3]
[1,] 1 2 3
[2,]
2008 Feb 20
1
Stress with MDS
Hi,
I am looking for the best multidimensional configuration for my data (47*47
distance matrix).
I ve tried classical metric (cmdscale) and non metric MDS (isoMDS, nmds)
but it is now difficult to choose the best solution because of the
uncertainties in the definitions of the "stress" function.
So, same problem, several questions :
1. Statistical consideration : With
2001 Oct 12
1
MASS: isoMDS and sammon
If tbl is an object of class 'dist', you can do this:
a <- sammon(tbl, k=3)
But you can't do this:
b <- isoMDS(tbl, k=3)
Wouldn't it be sensible to have identical interfaces to sammon()
and isoMDS() ?
I think all that would be needed is to change this:
isoMDS <- function(d, y=cmdscale(d, 2), maxit=50, trace=TRUE)
{
...into this:
isoMDS <-
2006 Jul 25
3
Overplotting: plot() invocation looks ugly ... suggestions?
Hi WizaRds,
I'd like to overplot UK fuel consumption per quarter over the course of five years.
Sounds simple enough?
Unless I'm missing something, the following seems very involved for what I'm trying to do. Any suggestions on simplifications?
The way I did it is awkward mainly because of the first call to plot ... but isn't this necessary, especially to set limits for the
2008 Feb 25
1
Plotting series marked with a symbol on every nth data point, preferably in ggplot...
Hello!
I am working with signals and a plot of several signals on the same
axes can get quite messy. With lines that are very fractured,
distinction by only the linestyle is not very clear. If I add symbols
to the plot however, there are so many symbols, that they overplot and
the whole plot is unreadable once again. I am looking for advice on
how to make a plot with continuous lines and symbols
2008 Dec 10
1
convert dataframe to matrix for cmdscale
I have a dataframe like this (toy example):
x y z
"a" "a" 0
"a" "b" 1
"a" "c" 2
"b" "a" .9
"b" "b" 0
"b" "c" 1.3
"c" "a" 2.2
"c" "b" 1.1
"c" "c" 0
The observations are from a matrix like this:
c 2.2 1.1 0.0
b 0.9 0.0
2011 Feb 18
1
segfault during example(svm)
If do:
> library("e1071")
> example(svm)
I get:
svm> data(iris)
svm> attach(iris)
svm> ## classification mode
svm> # default with factor response:
svm> model <- svm(Species ~ ., data = iris)
svm> # alternatively the traditional interface:
svm> x <- subset(iris, select = -Species)
svm> y <- Species
svm> model <- svm(x, y)
svm>