Hello!
The code below works - if you run it you'll see a stacked area chart
generated based on the data example.
I only have one understanding question about the legend location (the
very last snippet of code):
legend(par()$usr[2],
mean(par()$usr[3:4]),
rev(order.of.vars),
xpd=T,
bty=n,
, for Subject MO1:
y(M01) = (17.71+1.25)+(0.66+0.106)*Age+(-1.66-1.52)*SexFemale = 18.96
+ 0.766*Age -3.18*SexFemale
Question: Is there an easier way to get such an equation for each
level of Subject?
Thank you very much!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
,
e.g. graphs of coefficient shrinkage. So if this is the sort of thing
you want to do with the BLUPS, you may not need to do it manually.
HTH.
Cheers,
Bert
On Mon, Oct 18, 2010 at 2:15 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Hello!
If I run this example:
library
Gunter gunter.ber...@gene.com wrote:
Oh -- I get your question (I think). Not the total, just the random
effects. You have to add them to the fixed effects.
See e.g. p. 39 of Bates and Pinheiro.
-- Bert
On Mon, Oct 18, 2010 at 3:00 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote
(summary(regr.f)$adj.r.squared,3)
results[nrow(results)+1,1]-round(dwtest(regr.f)$statistic,2)
row.names(results)[(nrow(results)-2):nrow(results)]-c(R.Sqr,
Adj.R.Sqr,DW)
write.csv(results,file=file.name)
return(results)
}
--
Dimitri Liakhovitski
Ninah Consulting
, and then run my several graphs, e.g.:
for(i in 10:12){
plot(1:i)
}
Is there any way to avoid doing it manually initiate the graphics
recording in the RGraphics window in the script itself?
Thanks a lot for your help!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
, reproducible code.
--
Jim Holtman
Cincinnati, OH
+1 513 646 9390
What is the problem that you are trying to solve?
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman
)
floor(signif(x,3)+10)
But it's very manual - because in the problem I am facing the numbers
sometimes have to be rounded to a 1000, sometimes to a 100, etc.
Thanks a lot for any hints!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R
...@wlandres.net wrote:
On 20-Oct-10 21:27:46, Duncan Murdoch wrote:
On 20/10/2010 5:16 PM, Dimitri Liakhovitski wrote:
Hello!
I am trying to round the number always up - i.e., whatever the
positive number is, I would like it to round it to the closest 10 that
is higher than this number, the closest 100
Thanks a lot, David - I'll try this solution.
Dimitri
On Wed, Oct 20, 2010 at 9:54 PM, David Winsemius dwinsem...@comcast.net wrote:
On Oct 20, 2010, at 8:38 PM, Dimitri Liakhovitski wrote:
Thank you for your help, everyone.
Actually, I am building a lot of graphs (in a loop) but the values
defined inside the function?
Thank you very much!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting
://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r
. Look in the data frame
2. Look in the environment of the user-defined function
3. Look outside.
Dimitri
On Fri, Oct 22, 2010 at 9:15 AM, David Winsemius dwinsem...@comcast.net wrote:
On Oct 22, 2010, at 9:01 AM, Dimitri Liakhovitski wrote:
Dear R'ers,
I am fighting with a problem
AM, David Winsemius dwinsem...@comcast.net wrote:
On Oct 22, 2010, at 9:01 AM, Dimitri Liakhovitski wrote:
Dear R'ers,
I am fighting with a problem that is driving me crazy. I use lm in
my user-defined function, but it seems to be looking for weights
outside of my function's environment
(e.g., 1 milllion) using nrows= and skip.
I was able to read in the first 1,000,000 rows no problem in 45 sec.
But then I tried to skip 16,999,999 rows and then read in things. Then
R crashed. Should I try again - or is it too many rows to skip for R?
Thank you!
--
Dimitri Liakhovitski
Ninah
a lot!
Dimitri
On Fri, Oct 22, 2010 at 6:28 PM, Gabor Grothendieck
ggrothendi...@gmail.com wrote:
On Fri, Oct 22, 2010 at 5:17 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
I know I could figure it out empirically - but maybe based on your
experience you can tell me if it's doable
Grothendieck
ggrothendi...@gmail.com wrote:
On Fri, Oct 22, 2010 at 9:45 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Gabor,
thanks a lot - sqldf might be a solution. However, do you know if
sqldf can also read in .txt files (with different delimiters)?
The data I am dealing
Grothendieck
ggrothendi...@gmail.com wrote:
On Sat, Oct 23, 2010 at 9:20 AM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
This is very helpful, Gabor.
I've run the code to figure out the end of the line and here is what I
am seeing at the end of each line: \r\n
So, I specified like
:44 AM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Oh, I understand - I did not realize it's reading in the whole file.
So, is there any way to make it read it in only once and the spit into
R just one piece (e.g., 1 million rows), write a regular file out
(e.g., a txt using
O, wait a sec - does it mean I can't feed my objects into sql commands?
On Sat, Oct 23, 2010 at 10:07 AM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
I just tried it:
for(i in 11:16){ #i-11
start-Sys.time()
print(start)
flush.console()
filename-paste(skipped millions- ,i
-bit Windows 7 PC with 6 GB RAM (I assume
only 4 can be used?)) I got this error:
Error: cannot allocate vector of size 42.0 Mb
So, I guess
On Sat, Oct 23, 2010 at 10:19 AM, Gabor Grothendieck
ggrothendi...@gmail.com wrote:
On Sat, Oct 23, 2010 at 10:07 AM, Dimitri Liakhovitski
dimitri.liakhovit
,.txt,sep=)
write.table(DF,sep=\t,header=FALSE,file=filename)
count-count+1
}
close(con)
On Sat, Oct 23, 2010 at 10:19 AM, Gabor Grothendieck
ggrothendi...@gmail.com wrote:
On Sat, Oct 23, 2010 at 10:07 AM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
I just tried it:
for(i
Also am running the same code on my powerful home PC.
It's been running for 25 minutes already, and still has not printed
the first end time (does it mean it's still trying to read in DF for
the first time)?
On Sat, Oct 23, 2010 at 10:52 AM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com
I know that I can use as.yearmon in the package zoo to find the year
and the month of a date.
I can use as. yearqtr to find the year and the quarter.
But how can one find just the year of a date?
Thanks a lot!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
Thank you very much!
Dimitri
On Mon, Oct 25, 2010 at 12:46 PM, Gabor Grothendieck
ggrothendi...@gmail.com wrote:
On Mon, Oct 25, 2010 at 12:38 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
I know that I can use as.yearmon in the package zoo to find the year
and the month
Hello!
I am sorry if it's a naive/wrong question. But can one run a
regression with weights using lme?
Thank you!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r
are specified the same way as in
the lm function, and refers you to ?lm for details.
HTH,
Ista
On Tue, Oct 26, 2010 at 11:21 AM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Hello!
I am sorry if it's a naive/wrong question. But can one run a
regression with weights using lme
appreciate a clarification!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide
...@stat.wisc.edu wrote:
On Tue, Oct 26, 2010 at 12:27 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Hello,
and sorry for asking a question without the data - hope it can still
be answered:
I've run two things on the same data:
# Using lme:
mix.lme - lme(DV ~a+b+c+d+e+f+h+i
| Subject)
summary(fm1)
ranef(fm1)
When I run it like this I do get fixed effects in summary(my.model)
and I do get random coefficients by group (in my example - by Subject)
in ranef(fm1). I just want to make sure it's what I want.
Thanks a lot!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
and
installed R12 instead. But I am getting the same error.
Any advice?
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R
, Oct 29, 2010 at 9:22 AM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
I have just installed R-2.12
I have Windows 7, 64-bit verison.
I currently have IE as my default browser. The internet connection is very
good.
Whenever I try to run a help command (?lm, for example), I get
Problem solved. It turned out I had to reset my IE as my default
browser for all extentions (like .html). Now, R help is working!
Dimitri
On Fri, Oct 29, 2010 at 4:20 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
I tried one more thing - I uninstalled R again, and this time
Question: I installed R verison 2-12.0 on my Windows 7 (64 bit) PC.
When I was installing it, it did not ask me anything about 32 vs. 64 bit.
So, if I run R now - is it running as a 32-bit or a 64-bit?
thank you!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
wrote:
G'day Dimitri,
On Fri, 29 Oct 2010 16:45:00 -0400
Dimitri Liakhovitski dimitri.liakhovit...@gmail.com wrote:
Question: I installed R verison 2-12.0 on my Windows 7 (64 bit) PC.
When I was installing it, it did not ask me anything about 32 vs. 64
bit. So, if I run R now - is it running
-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read
PM, Dimitri Liakhovitski wrote:
You are asking a statistics question, not an R question. R-list people
never react to such posts.
Or they give you a nasty reply of the type: Do you homework first,
and then ask questions here.
Good point. I thought it was an R question because it was about
Hello!
I have 2 vectors:
x-letters[1:5]
y-1:3
Is there a way - without loops - to create a data frame such that we
repeat the whole y within each level of x so that it looks like
this:
a 1
a 2
a 3
b 1
b 2
b 3
c 1
c 2
c 3
etc?
Thank you!
--
Dimitri Liakhovitski
Ninah Consulting
Never mind - found it: expand.grid(y,x)
On Tue, Nov 2, 2010 at 4:57 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Hello!
I have 2 vectors:
x-letters[1:5]
y-1:3
Is there a way - without loops - to create a data frame such that we
repeat the whole y within each level of x
it.
Thanks a lot for your hints!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
this:
xtabs(value ~ city + brand, mydf)
On Wed, Nov 3, 2010 at 6:23 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Hello!
I have a data frame like this one:
mydf-data.frame(city=c(a,a,a,a,a,a,a,a,b,b,b,b,b,b,b,b),
brand=c(x,x,y,y,z,z,z,z,x,x,x,y,y,y,z,z),
value=c
In reshape2 this does the job:
dcast(mydf,city~brand,sum)
On Wed, Nov 3, 2010 at 4:37 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Thanks a lot!
Yes - I just found the reshape package too - and guess what, my math was
wrong!
reshape2 seems like the more up-to-date
Want to thank everyone once more for pointing in reshape direction.
Saved me about 16 hours of looping!
Dimitri
On Wed, Nov 3, 2010 at 4:38 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
In reshape2 this does the job:
dcast(mydf,city~brand,sum)
On Wed, Nov 3, 2010 at 4:37 PM
a b c d
loc 1 1/1/2010 1 11 111 NA
loc 2 1/1/2010 2 12 112 NA
loc 3 1/1/2010 3 13 113 NA
loc 1 2/1/2010 3 NA 114 1
loc 2 2/1/2010 5 NA 115 11
loc 3 2/1/2010 6 NA 116 111
Thanks a lot for your suggestions!
--
Dimitri Liakhovitski
Ninah
Never mind - I found it in reshape package: rbind.fill
I wonder if it's still in reshape2.
Dimitri
On Wed, Nov 3, 2010 at 5:34 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Hello!
I have 2 data frames like this (well, actually, I have 200 of them):
df1-data.frame(location=c
On Wed, Nov 3, 2010 at 4:32 PM, Henrique Dallazuanna www...@gmail.com wrote:
Try this:
xtabs(value ~ city + brand, mydf)
On Wed, Nov 3, 2010 at 6:23 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Hello!
I have a data frame like this one:
mydf-data.frame(city=c
it for
hundreds and hundreds of names in 100 of huge files (tens of
thousands of rows in each).
Any way to speed it up?
Thanks a lot!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman
the lookup table, and
my.df$category = categories[my.df$names]
creates the category column.
- Phil
On Mon, 8 Nov 2010, Dimitri Liakhovitski wrote:
Hello!
Hope there is a nifty way to speed up my code by avoiding loops.
My task is simple - analogous
!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self
) : cannot open the connection
Question: I'd like to program an if-then statement in my code that
says something like this:
myfile-read.csv(myfilename)
if cannot open the connection - then do X
What statement should I use under if?
Thanks a lot!
--
Dimitri Liakhovitski
Ninah Consulting
- data.frame(a = 1, b = 2, c = i)
if (i == 1) {
y - x
} else {
y - merge(x, y, all.x = TRUE, all.y = TRUE)
}
}
On Tue, Nov 9, 2010 at 8:42 AM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Hello!
I am running a loop. The result of each run of the loop is a data
frame
Thanks a lot, everybody- it's very helpful!
On Tue, Nov 9, 2010 at 12:20 PM, Nordlund, Dan (DSHS/RDA)
nord...@dshs.wa.gov wrote:
-Original Message-
From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-
project.org] On Behalf Of Dimitri Liakhovitski
Sent: Tuesday, November 09
!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self
spec...@stat.berkeley.edu
On Tue, 9 Nov 2010, Dimitri Liakhovitski wrote:
Hello!
I am running a loop. The result of each run of the loop is a data
frame. I am merging all the data frames.
For exampe:
The dataframe from run 1:
x-data.frame(a=1,b=2,c=3
On Tue, Nov 9, 2010 at 12:30 PM, Henrique Dallazuanna www...@gmail.com wrote:
Try this:
gsub(\\.(\\d{1}$), .0\\1, x)
On Tue, Nov 9, 2010 at 3:28 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Hello again!
Sorry, if it's a simple question - I am very bad in working
...@gmail.com wrote:
On Fri, Jul 9, 2010 at 9:35 AM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Hello!
Any hint would be greatly appreciated.
I have a data frame that contains (a) monthly dates and (b) a value
that corresponds to each month - see the data frame monthly below
Thank you very much, Gabor!
Dimitri
On Tue, Jul 13, 2010 at 12:25 PM, Gabor Grothendieck
ggrothendi...@gmail.com wrote:
On Tue, Jul 13, 2010 at 11:19 AM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Actually,
I realized that my task was a bit more complicated as I have different
- cbind(DV, lag(DV, 2))[idx,]
out-cbind(x, DVs[,2])
names(out)[length(out)]-DV.lead
return(out)
}
A
A.lead - do.call(rbind, by(A, A$group, lead.it))
A.lead
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
Never mind- I figured it out:
A
library(zoo)
z - read.zoo(A, index = 1, split = group, frequency = 1)
z - as.zooreg(z) ###
result-lag(z, c(-1, 0, 1))
A
result
Thank you very much!
On Wed, Jul 21, 2010 at 12:08 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Thank you, Gabor
21, 2010 at 12:12 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Never mind- I figured it out:
A
library(zoo)
z - read.zoo(A, index = 1, split = group, frequency = 1)
z - as.zooreg(z) ###
result-lag(z, c(-1, 0, 1))
A
result
Thank you very much!
On Wed, Jul 21, 2010 at 12
(out)]-DV.lag
return(out)
}
A
A.lagged - do.call(rbind, by(A, A$group, lag.it))
A.lagged
On Wed, Jul 21, 2010 at 12:18 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Sorry, I don't think it's working.
the last 3 columns (on the right) of result contain the original data
I reinstalled zoo and now I can see the years on left (raw names).
Before - I could not see them.
Thank you!
On Wed, Jul 21, 2010 at 12:51 PM, Gabor Grothendieck
ggrothendi...@gmail.com wrote:
On Wed, Jul 21, 2010 at 12:18 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Sorry, I
Thanks a lot, it's very helpful!
On Wed, Jul 21, 2010 at 1:21 PM, Gabor Grothendieck
ggrothendi...@gmail.com wrote:
On Wed, Jul 21, 2010 at 1:16 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
I reinstalled zoo and now I can see the years on left (raw names).
Before - I could
that just gives me the standardized
regression weights - even if I used weights for regression?
Thank you!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read
Hello!
I have a data set similar to the data set monthly in the example below:
monthly-data.frame(month=c(20090301,20090401,20090501,20100301,20100401,20090301,20090401,20090501,20100301,20100401),monthly.value=c(100,200,300,101,201,10,20,30,11,21),market=c(Market
A,Market A, Market A,Market A,
= 1 nor split =2 work.
And split =Brand does not work either. Why?
D.
On Fri, Jul 23, 2010 at 12:52 PM, David Winsemius
dwinsem...@comcast.net wrote:
?read.zoo
You didn't specify the index column correctly.
On Jul 23, 2010, at 12:36 PM, Dimitri Liakhovitski wrote:
Hello!
I have a data set
.
On Jul 23, 2010, at 1:01 PM, Dimitri Liakhovitski wrote:
Strange, I did attach. Attaching again. Maybe the file just doesn't go
through?
I have:
names(OrigData):
[1] Brand Month Value
I read ?read.zoo
According to that index should be the column number.
I thought it should be split = 1
...@comcast.net wrote:
On Jul 23, 2010, at 1:39 PM, Dimitri Liakhovitski wrote:
Very sorry - I mistunderstood and confused split with index.column -
totally my fault.
Ok, now I've run this line:
z - read.zoo(OrigData, index.column = 2, split = Brand)
And I am getting:
Error in merge.zoo
how to best save dates in
Excel if one saves them as .csv.
Dimitri
On Fri, Jul 23, 2010 at 2:00 PM, David Winsemius dwinsem...@comcast.net wrote:
On Jul 23, 2010, at 1:50 PM, Dimitri Liakhovitski wrote:
I am expecting to see the week names as row labels of z and the
corresponding values (like
])
beta - b * sx/sy
return(beta)
}
The above should do the trick.
TF
-Original Message-
From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org]
On Behalf Of Dimitri Liakhovitski
Sent: Thursday, July 22, 2010 12:35 PM
To: r-help@r-project.org
Subject: [R] does
-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
the question: my PC's memory is X. The
.txt tab-delimited file I am trying to read in has the size of YYY Mb,
can I read it in?
Thanks a lot!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https
Thanks a lot, it's very helpful!
Dimitri
On Tue, Aug 3, 2010 at 1:53 PM, Duncan Murdoch murdoch.dun...@gmail.com wrote:
On 03/08/2010 1:10 PM, Dimitri Liakhovitski wrote:
I understand the question I am about to ask is rather vague and
depends on the task and my PC memory. However, I'll give
And once one above the limit that Jim indicated - is there anything one can do?
Thank you!
Dimitri
On Tue, Aug 3, 2010 at 2:12 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Thanks a lot, it's very helpful!
Dimitri
On Tue, Aug 3, 2010 at 1:53 PM, Duncan Murdoch murdoch.dun
as it currently does?
2. In addition to 1, how can I ask zoo to actually keep the original
(monthly) values in each week of that month - rather than divide the
monthly value by the number of weeks?
Thanks a lot!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
, as.yearmon(mondays), function(x) zoo(x, rownames(x
Dimitri
On Wed, Aug 4, 2010 at 12:36 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Hello!
I have a code for converting monthly values into weekly values:
monthly-data.frame(month=c
- without
using a loop. I hope it's possible to do it without a loop - is it?
Thanks a lot!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting
Thank you very much, everyone!
Dimitri
On Wed, Aug 4, 2010 at 2:10 PM, David Winsemius dwinsem...@comcast.net wrote:
On Aug 4, 2010, at 1:42 PM, Dimitri Liakhovitski wrote:
I am sorry, I'd like to split my column (names) such that all the
beginning of a string (X..) is gone and only the rest
=FALSE)
str(x)
strsplit(x[[1]],split=\\..)
str(strsplit(x[[1]],split=\\..))
I am getting a list - hence, it looks like I have to go in a loop...?
Thank you!
Dimitri
On Wed, Aug 4, 2010 at 2:39 PM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Thank you very much, everyone!
Dimitri
exactly does the square bracket in your lapply
code mean? Looks like a shortcut - I've not seen it before.
lapply( strsplit(z[[1]],split=\\..), [, 1)
Thank you!
Dimitri
On Wed, Aug 4, 2010 at 3:31 PM, David Winsemius dwinsem...@comcast.net wrote:
On Aug 4, 2010, at 3:03 PM, Dimitri Liakhovitski
- like as.yearmon -
but for years?
Thank you!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting
http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
- for y (above z) - they'll be below zero
### and above zero we'll have a first and x second (on top of a).
Thanks a lot for your advice!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman
){
top.line.coords-bottom.y.coordinates+my.data[[var]]
bottom.coords-c(bottom.y.coordinates,rev(top.line.coords))
polygon(xx,bottom.coords,col=all.colors[which(names(my.data) %in% var)])
bottom.y.coordinates-top.line.coords
}
On Mon, Sep 27, 2010 at 11:47 AM, Dimitri Liakhovitski
$Date),
labels=unique(my.data.m$date)) +
scale_fill_manual(values=c(yellow, blue, green, orange)) +
theme_bw() +
ylab(Title of Y) +
opts(title=Chart title, axis.text.x=theme_text(angle=70, vjust=1, hjust=1))
HTH,
Ista
On Mon, Sep 27, 2010 at 6:05 PM, Dimitri Liakhovitski
0.9145508
[19] 8.4572754 9.2286377 14.6143188
Thanks a lot!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R
Hello!
I wrote a function that returns a data frame. Nowhere in the function
do I say print(my.data.frame), but when I run the function - the data
frame is printed on the console.
Is there any way to suppress it?
Thank you!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
Department of Statistics
UC Berkeley
spec...@stat.berkeley.edu
On Fri, 1 Oct 2010, Dimitri Liakhovitski wrote:
Hello!
I wrote a function that returns a data frame. Nowhere in the function
do I say
(top.line.coords))
polygon(xx,bottom.coords,col=all.colors[which(names(my.data) %in% var)])
bottom.y.coordinates-top.line.coords
}
grid(nx=NULL,ny=NULL,col = lightgray, lty = dotted,lwd = par(lwd))
axis(1, las = 2)
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
=0.7)
grid(nx=(length(my.data$date)-1),ny=NULL,col = lightgray, lty =
dotted,lwd = par(lwd))
Dimitri
On Mon, Oct 4, 2010 at 3:56 PM, David Winsemius dwinsem...@comcast.net wrote:
On Oct 4, 2010, at 3:28 PM, Dimitri Liakhovitski wrote:
Hello, everybody!
I have a code below that creates a data
-01),
%Y-%m-%d), at=my.data$date, las=2,cex.axis=0.7)
grid(nx=(length(my.data$date)-1),ny=NULL,col = lightgray, lty =
dotted,lwd = par(lwd))
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch
]]
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
--
Dimitri Liakhovitski
Ninah
!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self
Thnaks a lot, Duncan!
Running R as administrator solved the problem!
Dimitri
On Tue, Oct 5, 2010 at 9:07 AM, Duncan Murdoch murdoch.dun...@gmail.com wrote:
On 05/10/2010 8:58 AM, Dimitri Liakhovitski wrote:
Hello!
I've just installed R 2.11.1 on my new home PC. Just the base R. My PC
has
)])
bottom.y.coordinates-top.line.coords
}
axis(1, labels =format(as.Date(my.data$date, origin=1970-01-01),
%Y-%m-%d), at=my.data$date, las=2,cex.axis=0.7)
grid(nx=(length(my.data$date)-1),ny=NULL,col = lightgray, lty =
dotted,lwd = par(lwd))
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
Hello!
If you run the whole code below, it'll produce a stacked diagram. And
it looks good - because the tick-marks are aligned with the grid.
However, if I stretch the graph window, grid becomes misaligned with
the tickmarks. Or, rather, it seems aligned for the first and the last
tick mark, but
),
xpd=T,
bty=n,
pch=15,
col=all.colors)
Hope that helps.
-tgs
On Tue, Oct 5, 2010 at 10:33 AM, Dimitri Liakhovitski
dimitri.liakhovit...@gmail.com wrote:
Thanks a lot, Thomas.
May I ask 2 questions:
1. Is there a way to fill the legend rectangles with color
(currently, they just
Barry - thanks a lot, it's great. Now, the gridlines stick to the tick marks!
Just wondering why the product of grid does not.
D.
On Tue, Oct 5, 2010 at 11:07 AM, Barry Rowlingson
b.rowling...@lancaster.ac.uk wrote:
On Tue, Oct 5, 2010 at 3:37 PM, Dimitri Liakhovitski
dimitri.liakhovit
as a measured
variable, while it should be clear to reshape that time is NOT a
measured variable?
Thank you!
--
Dimitri Liakhovitski
Ninah Consulting
www.ninah.com
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE
-project.org
[mailto:r-help-boun...@r-project.org] Namens Dimitri Liakhovitski
Verzonden: dinsdag 5 oktober 2010 16:37
Aan: r-help@r-project.org
Onderwerp: [R] is there a way to avoid traveling grid?
Hello!
If you run the whole code below, it'll produce a stacked diagram. And
it looks good
1 - 100 of 627 matches
Mail list logo