Displaying 20 results from an estimated 20000 matches similar to: "Plotting question"
2000 Dec 20
1
Question about coplot() ...
Dear R-friends,
For the following data:
> xy
x y i
1 731 0.313 2
2 739 0.340 2
3 790 0.373 2
4 855 0.451 2
5 980 0.608 2
6 575 0.156 1
7 608 0.207 1
8 630 0.249 1
9 670 0.332 1
10 838 0.377 1
11 964 0.466 1
> coplot(y ~ x|i, data=xy)
coplot gives 3 panels, rather than 2, namely one for i=1 and one for
i=2.
Futhermore, when I extand data fram xy to have i=3 as follows:
2006 Dec 04
4
beginning my R-learning
Hello,
I'm just beginning to learn R. What books/online learning modules with
datasets would you suggest?
Thank you!
Best wishes,
Michael
____________________________________
Michael McCulloch
Pine Street Clinic
Pine Street Foundation
124 Pine Street, San Anselmo, CA 94960-2674
tel 415.407.1357
fax 415.485.1065
email: mm at pinest.org
web: www.pinest.org
2002 Jul 01
2
split a data frame
Hi ,
I have a data frame (Data1) which has a area variable (AREA) with
codes (RA,RG,LT etc.). I would like to split the data frame into
individual data frames called RA, RG, LT conatining only the
observations from those areas.
Thanks
yours sincerely
Andrew McCulloch
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read
2007 Dec 30
1
plot multiple data sets on same axis
I'm new to R and struggling to reproduce graphs I've made with gnuplot.
Example here:
http://www.slamb.org/tmp/one-active.png
I have three different data sets plotted on the same axis. (I also have
a number of samples for each X value which I displayed with quartiles
rather than plotting every point; that will likely be the subject of my
next question.)
My attempts to do this in R:
2010 Sep 23
4
Simple categorical scatter plot
New to R. I am trying to create a simple xy plot wherein the line
segment color is determined by a categorical column
The following does not change colors for me, probably because I don't
quite have a handle on either functions or value mapping syntax.
----------
time <- c(1, 2, 3, 7,10,11,14,16,20)
pressure <- c(0,10,20,20,50,18,60,65,90)
status <- c(0, 0, 1, 1, 1, 0, 3, 3,
2004 Dec 30
2
coplot with png: disappearing grid lines
Dear useRs,
When I use coplot() and output to png/jpeg/bmp, the grid lines from
the scatter plots disappear. If I output to pdf() the grid lines are
there, however I can't use it - I have many points, and the resulting
PDF file is large and very slow to open and scroll through. (By the
way, if I click File-Save As-png/jpeg/bmp from Rgui.exe, the grid
lines are preserved - but I need to use
2006 Dec 05
1
using R for survival analysis
Thank you to all who made very helpful suggestions to get started with R.
Duncan Murdoch raised an excellent question, asking about my background and
reason for using R. I'm an epidemiologist, applying the marginal structural
models approach (inverse probability of treatment weights) in a Cox
proportional hazards analysis.
The statistical program which I had been using does not have
2009 Aug 23
3
When factor is better than other types, such as vector and frame?
Hi,
It is easy to understand the types vector and frame.
But I am wondering why the type factor is designed in R. What is the
advantage of factor compare with other data types in R? Can somebody
give an example in which case the type factor is much better than
other data types?
Regards,
Peng
2004 Jun 05
2
More than one series in a coplot
Hi!
I would like to know, how do you plot more than one data series when
using "coplot"?
I think I know the answer if "plot" is being used:
x <- 1:10
y <- 1:10
y2 <- 1:10* 1.1
plot ( y ~ x, type="n" )
points( y ~ x, type = "b", col = "red" ) # plot the points and lines
for the first series
points( y2 ~ x, type = "b", col =
2004 Aug 26
1
coplot and par
R 1.9.1 on Win2000 or Win98SE.
I am using coplot as follows:
coplot(AVG~LRPI| REGION)
the output seems normal but I get:
"Warning message:
calling par(new=) with no plot"
This is the only explanation that I have for being unable to use par() with
coplot for changing the way the xlab and ylab appears. From within coplot I
can change the text itself but not the font, fontsize, etc,
2009 Feb 12
3
Adding abline in Lattice graph
Hi,I would like add a horizontal line at 126 (col=red) and a vertical line
at 6.5 ( col= blue) in each panel .How should I use the panel.abline
function in the following code I am using:
------------------
library(lattice)
with(reg.dat.5,coplot(lbxglu~lbxgh|eth,panel=panel.smooth,xlab="ABC",
ylab="FBG"))
----------------------------------------
Thanks a lot.
Professor of
2003 May 21
1
help on spatial data
Hi,
I have a dataset with x and y coordinates and in each point I have an
identity of point, in some cases I can have more then one identity by point.
My dataset is something like this:
> x <- rep(c(1:4),4)
> y <- rep(c(1:4),c(4,4,4,4))
> area1 <- sample(factor(rep(c("a","b","c","d"),4)))
> area2 <-
2008 Mar 04
4
colored 3d scatter plot
Hi All,
I have data for two groups, group with 100 points and group B with 15
points. i needed plot these two groups in one scatter plot, each group with
a different color. I tried
plot3d(data, col = c("red", "blue")[c(rep(1, 100), rep(2, 15))], pch=20) .
this works but the graph does not look good.
the other option that I tried is
scatterplot3d(data, type="p",
2004 Nov 26
1
Coplot Given text
Greetings:
I am unsuccessful in suppressing "Given : myvariable" from a coplot. There was such a question in the past but the thread breaks down. I am sure this is a "for dummies" question :-). I tried:
coplot(myvar~myvar | myvar, show.given=FALSE, xlab="....", ylab="...", main=" ")
and some other variations (including without main=" ")
2000 May 16
4
How do I add fitted curves to coplots?
G''day
I''ve been performing an analysis of some data by a follow the leader
method (Bad I know but it seems to work and I think I understand all the
steps now) and I''ve run into a problem. The analysis is for all practical
purposes identical to the non-linear mixed effects analysis performed on
Ludbrooks Rabbit data in the second edition of Venables & Ripley (page
2010 Jan 17
1
coplots with missing values
Hello - I'm trying to construct a coplot to check the residuals conditioned
on a factor using the following formula, however I keep getting an error
message. I've used the same formula for another data set and it worked fine
- the only difference is that now I have missing values for each level (2
levels) of the factor. Is this the problem and how can I fix it. Thank you.
> E2 <-
2011 Jul 22
2
Fit elipse to xy scatter
Hi,
I know there is a package 'elipse' available but I'm not sure how to use it
for my specific implementation.
What I would like to do is fit an elipse to two lines of identity (at right
angles to each other), as indicated in the following figure:
http://imageshack.us/photo/my-images/30/poincareplotwip.png/
Conceptually, I'm really struggling to even come up with a way of
2003 Nov 23
1
coplot row separatot line
Hi all,
I could not find a way to add the dashed horizontal separator line to the top
panel of a coplot (the one indicating which panel belongs to which range of the
given variable a in y~x | a).
This line should separate the ranges plotted in a row of panels in the panel
matrix below (hmmm, hope this is reasonably clear). I like it because it
enhances readability.
I'll try a sketch:
>
2008 Nov 03
3
descretizing xy data
Hello,
I have a dataset with a continuous independent variable (fish length, range:
30-150 mm) and a binary response (foraging success, 0 or 1). I want to
discretize fish length into 5 mm bins and give the proportion of individuals
who successfully foraged in each each size bin. I have used the cut function
to discretize the length values into my desired bins, but I can't figure out
how to
2008 Feb 19
1
How to use BayesTree or RBF for predict
Hi all,
sorry for my english, but I don't speak yours language.
I'm trying to use bart() and rbf(). The package I'm using now is
"BayesTree" and "neural", respectively. I could create the models, but I
can't predict my test data.
Does anyone have such an experience? Any advice is appreciated!
Thank you in advanced!.
Andr?
--
View this message in