Hi
>
> how do I plot only the data below 10? everything is white for the 0-10
and
> 10-90 is black ..
What data below 10? I do not see any. You posted some mails before but I
do not keep all mails from R. Only those which helped me somehow.
Basically
x <- sample(1:100, 100, raplace=TRUE)
x[x
Based upon my understanding of your problem, this should do the job:
> d3 <- dat1
> d3[2] <- ifelse( d3[2] == 1, dat2[1,2], NA )
> d3[3] <- ifelse( d3[3] == 1, dat2[2,2], NA )
> d3[4] <- "Nodata"
> d3[5] <- ifelse( d3[5] == 1, dat2[3,2], NA )
> d3$average <- rowMeans( d3[c(2,3,5)], na.rm = TRUE )
I forgot to mention, the Design package is deprecated (which suggest
your version of R is rather dated, current is 2.15). The rms package
replaces Design.
On Thu, May 10, 2012 at 10:23 PM, Joshua Wiley wrote:
> Hi Grace,
>
> I seem to have sent an empty draft before. Anyway, something like
> th
Hi Grace,
I seem to have sent an empty draft before. Anyway, something like
this might be an approach (untested):
require(rms)
set.seed(10)
dat <- data.frame(
age = rnorm(500, 40, 10),
race = factor(sample.int(2,500,TRUE), labels = c("a", "b")))
X <- model.matrix(~ age + race, data = dat)
b
Hi R user,
I saw some errors in the dat1.
The correct dat1 is
dat1 <- structure(list(X = structure(1:4, .Label = c("Plot1",
"Plot2", "plot3", "plot4"), class = "factor"), speciesX = c(1L, 0L, 0L, 1L),
speciesY =
c(0L, 1L, 0L, 0L), speciesZ = c(1L, 1L, 0L, 1L), speciesXX = c(1L, 0L, 1L,
0L))
Maybe with a larger sample of your dataset, 'info'.
merge should spread the average to all matching HTm, and with fake data it
does.
Rui Barradas
Daniel_55 wrote
>
> When I tried doing that, it only merged the averages from column 1 — ARI —
> and did not spread the averages for ARI, ATL, BAL. A
Hello,
Maybe
merge(five, fiveINFO[, c("HTm", "average")])
Hope this helps,
Rui Barradas
Daniel_55 wrote
>
> Hello,
>
> I am working with two different data frames, and I'd like to move data
> from one to the other. Here is the first frame:
>
>> head(five)
> Week Game.ID VTm V
Hello,
>
> I'm very frightened to lose datas or make mistakes
>
You wont lose rows, don't worry.
Two notes: merge uses the common columns in both data.frames, so by.x and
by.y aren't
really needed but they wont hurt.
And second, from the help page for 'attach', "attach can lead to confusion.
" Th
Are you getting caught on order of operations? Note that unary minus
has lower precedence than exponentiation (as it does in math) so
-2.5^(-2.4)
is
x <- 2.5^(-2.4)
-x
Otherwise, I'm not at all sure what your question is: can you give an
example of what you think you should get (and how to get
Rui Barradas wrote
>
>
> real^real is not necessarily real.
>
> The most well known example is (-1)^0.5 = imaginary unit.
>
Damn, can't believe it! It's a silly mistake!
Now that something wonders me is that when applying the Gaussian Hermit,
sum w f(x_i)
What happens when f(x_i) does not
Hello,
> Negative powers mean they take the reciprocal and as far as I am
> concerned, real^real is just a real number.
> Am I mistaking something basic?
Yes, you are.
real^real is not necessarily real.
The most well known example is (-1)^0.5 = imaginary unit.
When you say that -2.5^(-2.4) is r
Alekseiy, I tried your recommendation with several variations. It still does
not run. I think the problem has to do with R2.15 and the refreshed TM
package. Everything runs under R2.10 with the following code:
a <- Corpus(VectorSource(df$text)) # create corpus object
a <- tm_map(a, removePunctua
Hi,
I have been trying to run a pgmm estimation on a large unbalanced
dataframe (approx 226,000 obs) but I always get the following error text:
Error in u[1:nats[1], ] <- 0 : subscript out of bounds
The code that I run is:
baz <- pgmm(x ~ lag(x) | lag(x, 2:5),
data = foo,
effect
Did you ever get this to work? I am also having a problem with stemDocument
and removeWords. I think it is an issue with R 2.15 or the TM package
refresh because I can get everything to run under R2.10.
--
View this message in context:
http://r.789695.n4.nabble.com/Help-with-stemDocument-tp455452
Hi,
I know what complex number are, but I am not sure what you meant by that?
##CODES###
> 2.5^(-2.4)
[1] 0.1109032
> -2.5^(-2.4)
[1] -0.1109032
##CODES###
works fine.
Negative powers mean they take the reciprocal and as far as I am concerned,
real^real
Hello,
After all the trouble, workable datasets.
I have a doubt on what you want.
By looking at the two results data.frames, I don't believe they match the
problem description.
The average columns are wrong. Look at line 1 in table3a. I has speciesXX
with a value of 0.14
but speciesXX does NOT oc
Hi,
I have been asking only general questions even though I am using
basic R functionality. Hope there will be some ideas from the forum. I
am looking for a way to project workloads and capacity for software
servers. One book I have come across is 'Applied Linear Regression
Models'. I have
On Thu, May 10, 2012 at 7:41 PM, Grace Ma wrote:
> Hi,
> I am trying to simulate a regression on survival data under a few
> conditions:
> 1. Under different error distributions
> 2. Have the error term be dependent on the covariates
>
> But I'm not sure how to specify either conditions. I am usin
HI Michael,
It worked.
Thanks.
A.K.
- Original Message -
From: R. Michael Weylandt
To: arun
Cc: R help
Sent: Wednesday, May 9, 2012 11:32 PM
Subject: Re: [R] QQplots format
Hi,
car uses base graphics for this plot, so you can probably get what you
want with the layout() function.
how do I plot only the data below 10? everything is white for the 0-10 and
10-90 is black ..
those functions which do this?
was bad for such basic questions, but I started tinkering with R is 6 days
--
View this message in context:
http://r.789695.n4.nabble.com/Matrix-heatmap-tp4619084p4625021.ht
I tried to do using merge, I think now it works (anyway it is your worth), I
wrote:
df1<-read.csv("df1.csv",head=T)
attach(df1)
df2<-read.csv("df2.csv",head=T)
attach(df2)
join<-merge(df1,df2,by.x="name",by.y="name")
Is it correct? Coz I'm very frightened to lose datas or make mistakes
--
View
Hi R user,
I finally able to send you the table in
readable format. I have seen that some of you do send tables in email
when asking questions, but why i could not send. Any way
some of you helped me to send you the example table in a readable format.
now,
I want to concentrate on my probl
Hi R user,
I finally able to send you the table in
readable format. I have seen that some of you do send tables in email
when asking questions, but why i could not send. Any way
some of you helped me to send you the example table in a readable format.
now,
I want to concentrate on my prob
Hi,
I am trying to simulate a regression on survival data under a few
conditions:
1. Under different error distributions
2. Have the error term be dependent on the covariates
But I'm not sure how to specify either conditions. I am using the Design
package to perform the survival analysis using the
Hello All,
I am trying to color five subsets of points in a series of vertical strip
charts by quintiles using the quantile function, but I have not been able to
do this successfully, nor have I been able to find an example of this
online. I would like to have the "E1", "E2", and "E3" columns plo
When I tried doing that, it only merged the averages from column 1 — ARI —
and did not spread the averages for ARI, ATL, BAL. Any ideas on how I could
keep it from making all of the HTms ARI and all of the averages 19.4375?
--
View this message in context:
http://r.789695.n4.nabble.com/moving-da
Hi all,
I want to make the following:
I want to run a linear regression on each column of a matrix "estima" on
the correspondent column on the matrix "estima2".
You see I want to regress estima[,1] on estima2[,1] this way to all
columns
At the same time I want to make a regression adding e
Hi Mike,
as others have already suggested, there might be a problem with quoting.
Otherwise, did you already have a look at the package vignette (
http://cran.r-project.org/web/packages/XLConnect/vignettes/XLConnect.pdf
http://cran.r-project.org/web/packages/XLConnect/vignettes/XLConnect.pdf )
tha
Hello! I 'm new to R and need your help in one question...
I did cluster analysis using kmeans function. I load data from file:
This file also contains headers for objects I want to cluster.
After making a clustering procedure I display result on plot:
And it shows only points (i.e. objects) wit
Hello,
I am working with two different data frames, and I'd like to move data from
one to the other. Here is the first frame:
> head(five)
Week Game.ID VTm VPts HTm HPts HDifferential VDifferential
11 NFL_20050908_OAK@NE OAK 20 NE 3010 -10
21 NFL
Hi,
On Thu, May 10, 2012 at 8:35 PM, Lee wrote:
> Looking at the documentation for try() I am not sure how it would be best
> applied in this situation. My background is not extensively programming.
> Would writing a function first be appropriate?
>
> Also, I'm not sure just a simple error catch
> -Original Message-
> From: r-help-boun...@r-project.org [mailto:r-help-bounces@r-
> project.org] On Behalf Of Vikram Chhatre
> Sent: Thursday, May 10, 2012 4:57 PM
> To: r-help@r-project.org
> Subject: [R] Resampling question
>
> Hello -
>
> I have a population of 100 individuals that I
No, it will not, except possibly by chance: if the draws of sample are
IID (and they are supposed to be) there's no reason to expect them not
to overlap.
If you want that -- and I'm not sure it's totally on the level
bootstrapping-wise -- you need to decide which ones to remove all in
one fell swo
Looking at the documentation for try() I am not sure how it would be best
applied in this situation. My background is not extensively programming.
Would writing a function first be appropriate?
Also, I'm not sure just a simple error catch would solve my first problem.
I do, in fact, need it to plo
Hello -
I have a population of 100 individuals that I would like to bootstrap
10 times, every time removing 5 *different* individuals.
So far, I have done the following:
pop <- read.table('mypop.txt', header=FALSE)
replicate(10, sample(pop, 95, replace=FALSE))
I have not actually gone through
You should provide reproducible code and at the very least declare the
packages you are using. I guess this from the package raster? See
example in ?raster::interpolate:
## Thin plate spline interpolation with x and y only
library(fields)
r <- raster(system.file("external/test.grd", pa
Dear friends - I am trying to understand fda and working with the 2009
book from Springer. I run the scripts directly from a new installed fda
library and include sessionInfo() below. This is from the script
fdarm-ch09.R - I seem to have got not fda_2.2.8 but 2.2.7 - is that
the problem? Wher
Hi Carol,
> m1 <- rbind(c(1,2),c(3,4),c(5,6))
> m2 <- rbind(c(1,2),c(5,6))
> mylist <- list(m1)
> c(mylist, list(m2))
[[1]]
[,1] [,2]
[1,]12
[2,]34
[3,]56
[[2]]
[,1] [,2]
[1,]12
[2,]56
See the examples in ?c for more information.
Sarah
On Thu,
Hi,
It might be a trivial question but how do you store matrices of different
dimensions read from a file or in a loop together? The best solution might be a
list but I don't store the first matrix correctly:
m = rbind(c(1,2),c(3,4),c(5,6))
t=rbind(c(1,2),c(5,6))
l = list(m)
> l = list(l,t)
Well I'd suggest learning to use the return key. It really helps improve the
readability of a posting.
Three of the for files came through okay but table3a has a problem. It looks
like some kind of extraneous charater(s) got into it but a second or so of
editing makes it work so we have all 4
Do you want a qqnorm() instead of a qqplot() ? [Reproducibility also
involves posting the code you used that lead to the error / warning]
This seems to work for me:
# mydata <-
source("http://r.789695.n4.nabble.com/file/n4623493/mydata.txt";)[[1]]
# Have to drop visible attribute
lmmodel <- lm(
Kristi
The tables , if read in edit mode are vagely readable but please just do as
Petr and I suggest.
Use the dput command.
If you have the table in an R data.frame all you need to do is use the command
dput(mytable)
I read your two tables into R and did that . Note I called them dat1 & dat2.
library(parallel) # Requires R >=2.14
mclapply # a parallelized lapply()
You can process in parallel, but I'm not sure if it's safe to do
graphics in parallel: someone else will need to chime in about that.
Best,
Michael
On Thu, May 10, 2012 at 9:12 AM, Alaios wrote:
> Dear all,
> I am using my
write.csv() perhaps? I'm not sure what the csv of a raster image is though...
What does p look like? str(p) will be important -- if the raster codes
(RGB values) are in lists or 3D arrays or something more complex
(i.e., if no grayscale) you might need to put them in multiple files.
Hope this hel
oppps, Now I used 'dput' function. Again I am sending. I am so sorry for
inconvenience.
HI R userI am sorry that my data was not readable formate in the last email.
Agin I am trying to send it. hope this time, that table can be readable.As I
mentioned earlier that I was struggling to figure
Kristi,
Several people have already suggested you use dput() to provide your data.
In R,
dput(table1)
dput(table2)
Then copy and paste the output of those commands into your email.
There's no way to reliably copy and paste your raw data: using dput()
is the best way to provide it.
Sarah
On Th
Hi R-usuar,
I still find the table is not in readable formate. I now forwarded the
email.hope it works. I sent it to my account . It was perfect- but when I sent
it to R help- then it comes with unreadable formate. This is my last try. If
not, then I will try to do in Excel manually. cheers,
F
Hi John , Petr and R users
I am sorry that my data was not readable formate in the last email. Again I am
trying to send it. hope this time, that table can be readable.As I mentioned
earlier that I was struggling to figure out on how I can calculate the average
from the two tables in R. Any on
Dear all,
I have simple question regarding how to fit a model (i.e. linear) to the
data.
Say I have 10 subjects with different phenotypes (dependent var Y,
identical for a particular subject) and one predictor variable measured 3
times for each subject (X). By other words:
Y Subj X
1 1 1.2
1 1
Hi
what is wrong with
heatmap(as.matrix(test), col=my.colors(25))
with test from your dput
Regards
Petr
> The heat map generated the correct result:
>
> library(gplots)
> arq <-read.table("l")
> matrix_l <-data.matrix(arq)
> my.colors <-
> colorRampPalette(c
>
("gray0","gray10","gray20","gr
Hi Triss,
If you need to stem just one text in the Corupus use a[[n]]<-stemDocument
Best,
-Alex
From: r-help-boun...@r-project.org [r-help-boun...@r-project.org] on behalf of
Triss.Ashton [triss.ash...@unt.edu]
Sent: 02 May 2012 21:09
To: r-help@r-projec
Hi
as already mentioned your data can not be deciphered. Use
dput(table1) for sending usable data.
>From what you describe probably
?aggregate can be used.
But without suitable data you hardly get any advice.
Regards
Petr
>
>
> Hi R user,I am struggling to figure out on how I can calculate
Greetings R users,
My interest in the Q2cum score comes my endeavor to replicate SIMCAP
PLS-DA analysis in R. I use the exact same dataset. After doing the
analysis in R, I can get the exact same R2Ycum. However, the Q2cum is
significantly off. Adding the Q2cum of the 1st and 2nd component
com
Kristi,
Your data has come through in a totally unreadable layout.
Have a look at ?dput as a handy way to present sample data. Just run
dput(mydata), copy the output and paste into the email.
John Kane
Kingston ON Canada
> -Original Message-
> From: kristi.glo...@hotmail.com
> Sent:
Hi R user,I am struggling to figure out on how I can calculate the average from
the two tables in R. Any one can help me? really your help would be grateful-
I am spending so much time to figure it out. It should not be so hard, I think.
I have very big data but I have created a hypothetical d
On May 10, 2012, at 11:16 AM, Alaios wrote:
Dear all,
I would like to capture the NA values as produced from my code
the str over the return values return
int 61
int 65
int 69
int 73
int 101
int NA
int NA
it looks like that I am getting returned some integer values that
are NA and I w
With the sample data and the merge as above,
table(res2$phone)
454 2123 2342 9876 56775 87678
2 2 3 3 4 1
with(res2, table(name, request))
request
name book cigarettes drink food paper
Andy 0 1 00
Hello,
Try
station <- colnames(opencsv)[-1]
mat <- matrix(0, nrow=length(station), ncol=nrow(opencsv))
dimnames(mat) <- list(station, opencsv$Year)
for(st in station){
model <- lm(Year~opencsv[, st], data=opencsv)
mat[st, ] <- residuals(model)
}
write.csv(mat, "opencsv.csv")
Hop
Hello,
I'm glad it helped.
As for your second question, I don't know, but I'm not very comfortable with
the way you're doing things.
Why subtract the coefficients of model 1 from model 2?
And why the dummy? Why set model 1 to zero?
Isn't it better to use anova's F? After all, it's designed for i
In species distribution modeling where one uses a large sample of
background points to capture background variation in
presence\pseudo-absence or use\available models (0\1 response) it is
frequently recommended that one weight the data so the sum of the absence
weights is equal to the sum of pr
On 10-05-2012, at 17:16, Alaios wrote:
> Dear all,
> I would like to capture the NA values as produced from my code
> the str over the return values return
>
> int 61
> int 65
> int 69
> int 73
> int 101
> int NA
> int NA
>
> it looks like that I am getting returned some integer values th
Dear all,
I would like to capture the NA values as produced from my code
the str over the return values return
int 61
int 65
int 69
int 73
int 101
int NA
int NA
it looks like that I am getting returned some integer values that are NA and I
want to have an if statement for catching those
w
Dear R users,
I was wondering how I can convert a raster image (that made R through
interpolation) into an ascii or csv format?
this is the last line of my command
p <- interpolate(r, tpsfit)
So p is my raster file which I want to convert into ascii or csv
Many thanks
Regards
Mintewab
I don't quite follow what you are doing. Here is what Rui was suggesting using
your sample data
===
dat1 <- structure(list(name = structure(c(4L, 3L, 5L, 2L, 1L, 6L), .Label =
c("Andy",
"Bruce", "Ella", "John", "Luna", "Morgana"),
Hi there,
I am sure this question has been posted a couple times before but I could not
find a good solution on the web.
Is there any way to get png() support in R on SUSE linux? We want to run
GenePattern on that server and some workflows use R scripts plotting into pngs.
Best wishes
Kristia
thank you all for the high level contributions and the very helpful
feedback;
I think I have now enogh material to study for months: what a good lesson
learned!
cheers
max
--
View this message in context:
http://r.789695.n4.nabble.com/Dotchart-showing-mean-and-median-by-group-tp4619597p46235
Rui-
Thanks this definitely helps, just one quick question. How would you code
the values of chi-fm and chi-fms to change based on the degrees of freedom
of each model H(i)?
Meredith
Rui Barradas wrote
>
> Hello,
>
> Yes, it does help. Now we can see your data and what you're doing.
> What f
Hi Ruri, sorry for my vagueness. The problem is not the order.
I tried to merge the datasets as you wrote. The result is that when I input:
table(phone)
The output is:
0
And this happens for all the variables.
--
View this message in context:
http://r.789695.n4.nabble.com/Interweaving-of-two
Hi everybody,
thanks in advance for your help!
I am working with genetic data performing an NMDS to visualize the genetic
differentiation of individuals from different species and populations in
different site conditions (site variables are all factors), and actually
genetic data also.
The data b
Dear all,
I'm trying to debug my R package with valgrind, but I cannot get past the
point where I load make the data, as valgrind crashes when trying to
extract a single time series object of a multivariate mts object. I'm using
R 2.15.0 with platform x86_64-redhat-linux-gnu (64-bit).
The valgrin
Find the data attached,
http://r.789695.n4.nabble.com/file/n4623493/mydata.txt mydata.txt
The model would be /lmmodel <- lm(log(vdep) ~ v1 + sqrt(v2) + v3 +v5 + v6 +
v7 + v8 + v9 + v10, data = mydata)/
Thanks again,
u...@host.com
--
View this message in context:
http://r.789695.n4.nabble.
Hello,
What doesn't work, exactly?
I can only see two things:
1. The order of the columns is different, first data.frame in merge
instruction comes first.
Solution: reverse the order of data.frames in merge.
2. The order of the rows is different, the merge function orders it's output
by the c
> i need help in my coding
> the first line and the second line works and the ggplot works
> when i have a code like this and i want to fetch a map and saves it to
> a directory how can i put it
> because it gives me an error message
> Error in load(GGemz) : bad 'file' argument
>
> GGemz <- ggoo
I tried your proposition Sarah (I was answering to Berend when you posted
your answer).
Well it seems to work!
I just had to add afterwords a line to have my NAs again.
I converted values = 0 by NA (numeric() in the function did the contrary for
the calculation):
mydata[mydata==0] <- NA
At firs
Hi David,
Thank you for your suggestions. I am quite the beginner at R and don’t
understand how to actually implement your suggestion and am hoping for some
further advice on that, if possible.
This is a subset of my data. Rows are host species, and columns parasite
species. Three of the parasite
cernst mail.mcgill.ca> writes:
>
> I'm pretty new to R and would appreciate some help interpreting the output of
> a function that was recommended to me.
>
> I've used the *envfit *function in the vegan package to plot vectors of four
> climate variables onto a species matrix ordination. The o
Hi guys,
I am applying linear regression model using lm, generate the residual
and then need to output the result to a csv file. Here is my script:
maxtempstation1.lm = lm( Year ~ station1, data=opencsv)
maxstation1.res = resid(maxstation1.lm); maxstation1.res
write.csv(maxtempstation1.res, file="
What about using a Portable Apps style packaging of R? That might solve some
of the issues.
--
View this message in context:
http://r.789695.n4.nabble.com/registry-vulnerabilities-in-R-tp4619217p4623388.html
Sent from the R help mailing list archive at Nabble.com.
___
I'm pretty new to R and would appreciate some help interpreting the output of
a function that was recommended to me.
I've used the *envfit *function in the vegan package to plot vectors of four
climate variables onto a species matrix ordination. The output indicates
that only a single variable (m
Hi Jim, hi John,
thank you very much for your tips. The "plotrix" package solves the problem!
However, thank you also for the advice that my way of plotting the data
might not be the best. I will think about it.
So once again thanx !
--
View this message in context:
http://r.789695.n4.nabble.c
Dear all,
I am using my code the vgram.matrix of packets fields. I have around 500
matrices that I need to pass inside that function and then plot those results.
Even though my system has 16 cores is quite clear that I am only using one of
those.
Would it be able to skip these 500 "tasks" to the
I have tried the diff and lag function.
I have given an example below. Diff gives me a$var2.shift.
I want a$var2.noshift, i.e. var^(t+2)-var^(t) should stay in the row with
year=t.
Diff shifts it to the t+2 row.
> a <- data.frame(c(rep(2,5), rep(3,5)), c(2005:2009, 2004:2008),
c(NA,10,34,23,12, 2
Has any mentioned
?make.names
On Thu, May 10, 2012 at 8:39 AM, Wincent wrote:
> As I said, the file name is derived automatically from text processing.
> Thanks all the same.
>
> On 10 May 2012 20:35, Upton, Stephen (Steve) (CIV) wrote:
>> Why not just construct a valid file name and use that i
You're moving the goal posts. If you need to deal with internal as
well as terminal NA values in a particular way, it would help to have
told us that up front.
Please give us some sample data that illustrates what you're really
trying to work with, and a full explanation of what you need to
accomp
Thanks for your answer too Berend.
Yes you're right about x[i+1]. You answered juste before me.
Well your idea of declaring all in numeric is great. It avoids my problem.
But actually I also have small missing data gaps in the rest of my data (in
the middle of numeric values).
And one of the aim of
As I said, the file name is derived automatically from text processing.
Thanks all the same.
On 10 May 2012 20:35, Upton, Stephen (Steve) (CIV) wrote:
> Why not just construct a valid file name and use that in cat? You can then use
> file.path to join paths together if you want to write to a spec
Oh, yes of course. Thanks.
I really don't like dual plots. I ran into one a few days ago that looked to me
to be very dubious but I don't have the raw data to replot it in another form.
It's a side issue so I'm not going to bother about it but is annoyed me.
John Kane
Kingston ON Canada
Why not just construct a valid file name and use that in cat? You can then use
file.path to join paths together if you want to write to a specific location,
as in your example.
steve
-Original Message-
From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On
Behalf O
On Thu, May 10, 2012 at 8:02 AM, jeff6868
wrote:
> Thank you for your reply sarah.
> Well actually I don't try to access x[i+1]. The line where you saw it starts
> with #. It was just try I wanted to keep (sorry I should have removed it
> before posting).
Sorry, I should really have more coffee b
On 12-05-10 7:38 AM, Brian Smith wrote:
Hi,
I was trying to change some code in an existing package. I downloaded the
source package (say 'package_xx') from CRAN, and changed the R code
provided in the /package_xx/R/xx.R. I then saved the changes and did the R
CMD INSTALL -l /path to modified pa
On May 10, 2012, at 8:07 AM, John Kane wrote:
I don't think there is any other way.
There is:
a <- c(10, 20, 30, 40)
b <- c(50, 250, 500, 600)
ba <- b/a
par(las=1, mar=c(5,5,.5,5))
plot(a,b, type="b", pch=22, cex=2, col=4, lwd=2, ylim=c(0,650),
xlim=c(0,45))
par(new=TRUE)
plot(a,ba,ty
Hi,
I am using ggplot2 and arrange differnet plots into
one viewport by dividing it into rows and columns:
pushViewport(viewport(layout = grid.layout(nrow=2,ncol=2,widths = unit(c(50,
50), "mm"),heights = unit(c(50, 50), "mm"
with following function I can extract the legend of a previously
On Thu, May 10, 2012 at 2:24 AM, maxbre wrote:
> hi all
>
> I have another question reated to the dotchart: is it possible by means of
> par() to set a logaritmic scale?
> If yes, how ? and if not, any alternative solution?
>
1. This is getting increasingly complicated as new requirements are
add
I don't think there is any other way. On the other hand, most gurus suggest
that a dual scales on a graph are not a good thing.
What about using a two panel graph?
Quick rejigging of your code :
=
a <- c(10, 20, 30, 40)
b <- c(50
On 05/10/2012 09:37 PM, pannigh wrote:
Dear list,
I am looking for a possibility to present results in a more graphical way by
adding an axis. But I have trouble relating my data to the added axis.
Imagine the following example:
a<- c(10, 20, 30, 40)
b<- c(50, 250, 500, 600)
ba<- b/a
par(las=1,
Thank you for your reply sarah.
Well actually I don't try to access x[i+1]. The line where you saw it starts
with #. It was just try I wanted to keep (sorry I should have removed it
before posting).
But I ask him to access to the next value if conditions in the loop are not
verified (restart the c
On 10-05-2012, at 12:59, Sarah Goslee wrote:
> Well, if i goes from 2 to length(x) and you try to access x[i+1], of
> course odd things will happen. Why not construct the loop to
> (length(x)-1) instead, so that x[i+1] is defined.
>
The reference to x[i+1] in a commented line so I don't think
On 08/05/2012, arun wrote:
> Hi Vihan,
>
> The link below might be helpful.
>
>
> (http://stackoverflow.com/questions/3415097/controlling-number-formatting-at-axis-of-r-plots)
Thanks, the xaxt parameter in plot() solved the problem.
Thanks and Cheers!
- vihan
>
> A.K.
>
>
>
>
>
>
>
> - Ori
On 08/05/2012, John Kane wrote:
> Actually I meant a working example and some data (See ?dput for a handy way
> to supply data)
>
> It is also a good idea to include the information from sessionInfo()
>
>
> I think David W has a good approach.
>
> Otherwise you might just want to write the axis y
Dear list,
I am looking for a possibility to present results in a more graphical way by
adding an axis. But I have trouble relating my data to the added axis.
Imagine the following example:
a <- c(10, 20, 30, 40)
b <- c(50, 250, 500, 600)
ba <- b/a
par(las=1, mar=c(5,5,.5,5))
plot(a,b, type
1 - 100 of 119 matches
Mail list logo