Displaying 20 results from an estimated 4000 matches similar to: "Scatterplot Question"
2011 Jan 14
9
Selecting the first occurrence of a value after an occurrence of a different value
Hello everyone,
I am currently working with some data where I need to select the first
occurrence of a value after the occurrence of another value.
The data has two columns, one with a time and one with occurence of certain
events.
The column of data I want to select from looks like this (and each of these
events have a corresponding time in another column).
Stat71
OutMag
FirstResp
InMag
2012 Dec 19
1
Display of data points in the Scatterplot
Respected R forum
I am learning R and relatively quite new to R. I am generating a scatter-plot as given below. (My actual table is much larger).
# Sample data frame
y = c(20, 23, 17, 31, 68)
x = c(200, 300, 400, 500, 600)
plot(x, y, type = 'l')
If I plot this scatter-plot in excel, the data values are displayed if I place the cursor at some desired place of the graph. E.g. if I
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) <-
2007 May 14
1
cross-validation / sensitivity anaylsis for logistic regression model
Hi,
I have developed a logistic regression model in the form of (factor_1~ numeric
+ factor_2) and would like to perform a cross-validation or some similar
form of sensitivity analysis on this model.
using cv.glm() from the boot package:
# dataframe from which model was built in 'z'
# model is called 'm_geo.lrm'
# as suggested in the man page for a binomial model:
cost <-
2008 Dec 12
2
Extracting the name of an object into a character string and vice versa
I am still struggling to map a character string to an object name and
vice versa in R.
I thought the as.name() function might work, but observe the following
behaviour ...
> attach(warpbreaks)
> levels(tension)
[1] "L" "M" "H"
> levels(as.name("tension"))
NULL
> objectname<-as.name("tension")
> objectname
tension
>
2001 Oct 26
1
Getting started with Time Series
Anyone have a good R tutorial for time series? Or know
of a good book? Any advice would be helpful. I've
been using matlab and programming things directly (not
using canned functions), but now I'm having difficulty
figuring out how to say, do freq domain anaylsis and
get a CI on my periodogram, or plotting the coherence,
etc. Or how to change certain parameters, e.g. fit
AR(p) with p
2010 Apr 25
1
categorical variable in scatterplot (car)
Hello R folks,
I am encountering a problem with the following scatterplot function from the
car package:
> scatterplot(y~x|z)
where y and x are continuous (interval) random variables and z is a
categorical variable. When z is a categorical variable coded 1 or 2, I
(appropriately) get a scatterplot of y by x, coded by z. Similarly, when z
is a categorical variable coded 1, 2, or 3, there is
2007 Jan 21
1
Scatterplot help
Hi my friends,
I'm trying to make a scatterplot like this.
1) I have a 3-variable dataset. They are ID, x, and y.
2) "x" is for the X-axis, "y" for the Y-axis, and "ID" is used to label all
the cases in the scatterplot.
3) After creating the scatterplot, I need to add both a X-axis reference
line and a Y-axis reference line. The X-axis reference line is a
2008 Feb 11
1
scatterplot in CAR
I am trying to use scatterplot function in CAR like the following:
scatterplot(X~Y)
I want to label X points and Y ponits using the different color.
Any idea for this?
Aimin
2011 Feb 08
1
How to change labels in scatterplot?
Dear all,
I'm trying to use "scatterplot" from package "car" to get a scatterplot with
row-names as labels and I want my data to be divided into two groups defined
by the column "tresh". Leaving away the groups-command gives me the right
labels but they are not distinguished by colors according to "tresh". Does
anybody know why the following example
2012 Oct 23
1
scatterplot with wrong line offset
Hi All,
I'm trying to do a Scatterplot (package: car), and add a line (just for
reference).
There is my code:
#------------------------------------Code---------------------------------------------------
library("car")
library("calibrate")
G_T<-c("car","bike","boat")
ave<-c(80,10,45)
perf<-c(100,80,75)
df2<-data.frame(G_T,ave,perf)
2009 May 01
1
Plotting extra lines on scatterplot
Hello Everyone-
I'm in the process of slowly learning R and am having a little bit of
trouble plotting an extra line onto a scatterplot. I'm sure the answer
is quite simple but I am stumped.
The code I am using is:
headways <- read.table("headways.csv", header=TRUE, sep=",",
na.strings="", dec=".", strip.white=TRUE)
plot.new()
2006 Feb 01
1
Scatterplot color options in CAR package?
Hi All.
I'd like to change the default plotting colors used to construct a
scatterplot with regression line in the CAR package.
So,
scatterplot(y~pred,smooth=FALSE, xlab="X", ylab="Y", lwd=2)
If I change the palette (e.g., palette(ranbow(6)), I can change the color of
the lines and points.
However, the axes and labels remain in black (i.e., the first color in the
2009 Feb 19
1
modifying legend in scatterplot matrix R
Hello R users,
I have some troubles to modify the "per default" legend in the
scatterplot.matrix using the car package. Here is my code:
--------------------------------------------------------------------
scatterplot.matrix(~ a + b + c,
groups=treatment,
by.groups=F,
data=newfile3,
smooth=T,
pch=c(16,4),
cex=1.3,
2011 Nov 07
0
Adding lines to scatterplot odd result when creating multiple plots
Dear R helpers
I'm attempting to create a matrix of scatterplots with X-Y mean lines and
regression lines added to each plot in the matrix. I have managed to create
the first plot I would like using scatterplot but have run into an odd
result when I use par() to set up the page to take multiple plot.
Specifically, the mean and regression lines appear to plot in the second
plot window, not
2010 Nov 16
5
scatterplot with filled circles
for a simple scatterplot:
plot(X ~ Y, type = 'p', col = 'red')
this produces red-edged circles, but I want to fill in the circles.
can this be done? I checked '? plot' already but couldn't find what I was
looking for.
cheers
--
View this message in context: http://r.789695.n4.nabble.com/scatterplot-with-filled-circles-tp3044690p3044690.html
Sent from the R
2006 Jun 16
2
scatterplot but a little tricky
i have two vectors of numbers x and y and of course i
can do the standard scatterplot plot(x,y)
and it looks fine. But, I was hoping there was a way to
do the scatterplot so that each point plotted is a number
where the number represents the index in the dataset.
so, if it was x[3] and y[3], then the point would be a 3
or if it was x[4] and y[4], then the point would be a 4 etc.
i doubt this is
2011 Jun 04
1
nonparametric logistic regression based on locally weighted scatterplot smoothing (lowess)
Dear UseRs:
Recently, I have read an article regarding the association between age and
lymph node metastases.
http://jco.ascopubs.org/content/27/18/2931.long
In statistical analysis, the authors stated "Because a nonlinear
relationship between age and lymph node involvement was expected based on
existing literature, lymph node involvement was also regressed on age using
nonparametric
2007 Jul 19
2
Trend lines on a scatterplot matrix
I'm using pairs() to generate a scatterplot matrix;
pairs(~ Fuzzy.gray.white.ratio+Fuzzy.gw.t.score+AgeWhenTested+signal_mean.noise,
data=datam,subset=status=="control",main="Controls",
labels=c("G/W","Peak Separation","Age","S/N"))
How can I add regression lines to the plots?
2004 Dec 23
3
combination of scatterplot and image graph
Dear R users,
I'm interested in a combination of a scatterplot and an image graph.
I have two large vectors. Because in the scatterplot some areas are
sparsely and others densely populated, I want to see the points, and
I also want their color to be changed based on their density (similar
to a heat map). Is there a function that can do that?
Thank you,
b.