Displaying 20 results from an estimated 7000 matches similar to: "overlaying plots"
2008 Nov 08
2
lines, ecdf and colors
Hi. I'm trying to plot two ecdf's on the same graph using two
different colors. I can plot using the same color, but it doesn't
work when I change colors? Any suggestions? Thanks in advance for
your help.
x <- c(0.80, 0.83, 1.89, 1.04, 1.45, 1.38, 1.91, 1.64, 0.73, 1.46)
y <- c(1.15, 0.88, 0.90, 0.74, 1.21)
plot(ecdf(x))
# it works without col='blue', but doesn't
2005 Jul 27
2
Returning positions of a vector
Hi,
I'd like to return the rows of sampled values of a vector. Can't figure
out how to do it.
For example: I start with [3, 1, 7, 4, 10] that have position
[1,2,3,4,5]. I sample [10,1,4] and I want to return [5,2,4].
I'm sure there's a simple way to do that but haven't been able to figure
it out or locate it.
Thanks in advance...mj
[[alternative HTML version
2007 Nov 16
1
How to save multiple graphs into a single file
Hi,
I have searched the archives and help manuals and can not find anything
regarding how to save multiple plots/graphs into a single for example,
pdf file. There is plenty of discussion etc. about saving a single plot
to a single file, but not multiple plots to a single file. Is it
possible? I can't want to use lattice, because I have hundreds of plots.
So, to keep it simple, let's say
2001 Oct 22
3
Two questions
Greetings,
I have two questions that I could not answer from the
documentation.
A - ecdf and confidence intervals : Is there a (simple) way to generate
confidence intervals (95%) for a ecdf?
B - cross-validation of rpart trees : a colleague is using S to
generate decision tree and mentioned to me the use of cross-validation. Is
this function enabled in R ? if so, how should one proceed to
2005 Nov 09
6
elements in a matrix to a vector
hi all,
i'm trying to get elements in a matrix into a vector. i need a
"streamlined" way to do it as the way i'm doing it is not very
serviceable. an example is a 3x3 matrix like
0 0 3
2 0 0
0 4 0
to a vector like
3 2 4
thanks...mj
[[alternative HTML version deleted]]
2004 May 03
1
plotting in R
Hi there, I have 2 questions which I cannot find answers for in Dalgaard
or the helpfiles currently available.
(1) I wish to plot 3 ecdf plots on one graph. Is there any way of
holding a figure to plot all on the same plot. I can't get an ecdf for
any plot command other than "plot" or "ecdf.plot" so using lower level
command is no good, have also tried x11().
(2) If
2007 Dec 19
1
want to make a plot similar to ecdf
I have a sample of observations:
> yy
[1] 0.00000000 2.39722222 4.35000000 -4.19722222 0.63611111
[6] 1.08055556 5.90555556 -1.87222222 2.13333333 -1.18055556
[11] 3.61666667 0.87777778 8.33888889 3.84166667 1.11111111
[16] -3.76111111 -11.67777778 -2.03055556 6.94444444 -11.76666667
[21] 4.81111111 -7.25833333 1.42222222 5.37222222 4.68055556
2007 Jun 09
1
What ECDF function?
Hello!
I want to plot a P-P plot. So I've implemented this function:
ppplot <- function(x,dist,...)
{
pdf <- get(paste("p",dist,sep=""),mode="function");
x <- sort(x);
plot( pdf(x,...), ecdf(x)(x));
}
I have two questions:
1. Is it right to draw as reference line the following:
xx <- pdf(x,...);
yy <- ecdf(x)(x);
l <- lm(
2006 Apr 20
2
smooth the ecdf plots
Hi All,
I have codes as follows to get the ecdf plots:
>
day.hos2<-c(6,4,6,6,4,6,5,4,7,5,6,6,8,6,17,9,8,4,6,3,5,8,7,12,5,10,6,4,6
,13,7,6,6,25,4,9,96,6,6,6,6,9,4,5,5,4,10,5,7,6)
>
day.hos3<-c(5,6,7,6,4,5,6,6,6,6,19,7,5,9,8,8,7,5,6,20,40,5,8,7,7,5,6,13,
11,9,4,6,9,16,6,7,6)
> f<-ecdf(day.hos2)
> plot(f,col.p='red',col.h='red')
>
2010 Nov 25
1
overlap cdf plots and add colors and etc
Hi r-users,
I would like to overlap 2 ecdf plots.
I tried this below and it gives me two plots of ecdf but just both just in
black.
par(mar=c(4,4,2,1.2),oma=c(0,0,0,0),xaxs="i", yaxs="i")
plot(ecdf(datobs))
lines(ecdf(gam_sum_gen))
Then I try to add colors etc and also the legend but fail.
par(mar=c(4,4,2,1.2),oma=c(0,0,0,0),xaxs="i", yaxs="i")
2009 Jul 03
3
Color of ecdf plots
Hi.
I have the following two ecdf plots in one graph:
plot(
ecdf(....),
do.points=FALSE,
verticals=TRUE,
main=paste("Ecdf of distances ",DIM,sep=""),
col="red"
);
lines(
ecdf(....),
do.points=FALSE,
verticals=TRUE
);
How do I change the color of the resulting graph? Adding col="red" to either plot or lines results in an error
2010 Jun 17
1
Multiple ecdf plots?
I have a csv file that has approximately 50k rows. In the first value of
each row, a file name is listed, and there are 162 different file names. At
the end of each row, there is a number value. What I would like to be able
to do is for the 162 different files (or we could call them categories), is
compute the ecdf for the values within that category. Then plot the ecdf
for each file on the
2004 Jun 03
1
ecdf plots, lines, and y values
Hi,
I have a question for the group, perhaps someone can help me
figure this out. I've already looked in the help files and they were
no help to me.
I have a vector of values and I am plotting an ecdf graph.
1. How can i draw a continuous line through the ecdf points? (lines
and type for the plot with an ecdf object does not work)
2. Supposing I have this line drawn. I can add a
2005 Sep 21
3
Multiple density plots on 1 graph
I want to overlay 50 denisty plots on a single plot.
For each plot there are 10,000 data points and i want
the empirical density of the data. I have not been
able to find an easy way to achieve this (I have
scoured the manula and website so sorry if I missed
it!), does anyone have any suggestions?
Thankyou.
2005 Nov 15
3
Reading in a table with unequal columns
Hi,
Wasn't sure how to explain this problem succinctly in a title. I am
trying to read in a text file that looks like:
0 1000 175 1 2 3
1 1000 58 0 2 9
2 1000 35 0 1 3 10
3 1000 300 0 2 4 5 10 11 18
4 1000 150 3 5 6
5 1000 100 3 4 6 7 18
6 1000 50 4 5 7 8
7 1000 155 5 6 8 19
8 1000 255 6 7 19
9 1000 200 1 10 12
10 1000 52
2003 Jul 21
3
Confidence Band for empirical distribution function
Hi,
I was trying to draw an empirical distribution function with uniform
confidence bands. So I tried to find a way to calculate values of the
Kolmogorov-Smirnov Distribution but failed.
I guess it must be hidden somewhere (since the ks-test is implemented),
but I was unable to find it.
Is there any way to do this?
Thanks
Leif Boysen
2011 Oct 16
2
ecdf
Hi,
Newbie here. I read the R for Beginners but i still don't get this.
I have the following data (this is just an example) in a CSV file:
courseid numstudents
101 209
141 13
246 140
263 8
321 10
361 10
364 28
365 25
366 23
367
2011 Jan 26
2
2 functions with same name - what to do to get the one I want
There seems to be 2 functions call ecdf...
http://lib.stat.cmu.edu/S/Harrell/help/Hmisc/html/ecdf.html
http://127.0.0.1:11885/library/stats/html/ecdf.html
How do I get the one ecdf {Hmisc} to run instead of the ecdf {stats}
A pointer in the right direction would be greatly appreciated.
Tried to instal Hmisc but got this message, so I assume I have it
> utils:::menuInstallPkgs()
Warning:
2011 Feb 10
1
How to determine the quantile boundary from an ECDF?
Given a dataset x, the ecdf is ecdf(x). Then I can use ecdf(x)(y) to find
the percentile of y. Given the ecdf is there a way to determine what is the
value of y that is the boundary of let's say 95 percentile? In other words,
is there a function I can call on the ecdf like:
fomeFunc( ecdf( x ), 0.95 )
Which will return the highest value of y, for which ecdf( y ) < 0.95?
The only solution
2005 May 31
2
Null space (or kernel) and image of a matrix
Hello!
Does anyone now if there exist a function that would compute a "null space"
(or "kernel" - "Ker") of a matrix and maybe also one that would compute an
"image" ("Im") of a matrix.
I tried R-site search and google, However I found notnihg useful!
Thanks for any sugestions! I am also not sure what an "image" of a matrix
is, so