Re: [R] Bug in seq.date?

2007-06-04 Thread Jonne Zutt
, resulting in: 01-31, 02-31, 03-31, 04-31, 05-31, etc Then, for the illegal dates it counts forward. 04-31 becomes 05-01, etc Jonne. On Mon, 2007-06-04 at 09:39 +0200, hadley wickham wrote: seq(as.Date(2000-1-1), as.Date(2001-1-1), months) [1] 2000-01-01 2000-02-01 2000-03-01 2000-04-01

Re: [R] Dropdown boxes in tcltk and R

2007-05-14 Thread Jonne Zutt
Hi Jake, Two things I noticed: - Don't tkdestroy(tt) too soon, you use comboBox later. - Don't use fruitChoice in OnOK if you only define it at the very end of your program. Here's your code with these two modifications. Greets, Jonne. require(tcltk) tclRequire(BWidget) tt - tktoplevel

Re: [R] barplot with different color combination for each bar

2007-03-05 Thread Jonne Zutt
Hi, I'd suggest you use ?rect for this. Here's an example (I did not check whether it's correct...) I also improved (but not checked :) your definition of cols. Jonne. X - seq(1:6) Q - matrix(sample(X, 60, replace = T), nrow=6, byrow = T) H - matrix(rep(1,60), nrow=6, byrow=T) color - c(blue

Re: [R] How to find series of small numbers in a big vector?

2007-01-30 Thread Jonne Zutt
I suggest the following appraoch This gives TRUE for all data within the search_range A1 = my_data search_range[1] my_data search_range[2] which() gives us the indices A2 = which(A1) and diff() the gaps between those intervals A3 = diff(A2) Hence, if A3

Re: [R] export many plots to one file

2007-01-07 Thread Jonne Zutt
Another thing to think about is about each individual scatter plot. Aren't you plotting too much duplicate (x,y) values? You could try to plot only unique values, or even try to filter out points that are very close. __ R-help@stat.math.ethz.ch mailing

Re: [R] Add line to plot. The line falls outside the current plot.

2006-12-21 Thread Jonne Zutt
Use xlim and ylim to your call to plot (see ?plot and ?par). So, plot(..your.parameters.., xlim=c(minx, maxx), ylim=c(miny,maxy)) Replace minx,maxx,miny,maxy by numbers. Usually, the function range() comes in very handy here, see ?range Jonne. On Thu, 2006-12-21 at 04:38 -0800, [EMAIL

Re: [R] return()

2006-12-18 Thread Jonne Zutt
Well, put it in a list and return that list. It's all written in ?return by the way. [EMAIL PROTECTED] wrote: Dear R Help, Why is it that if you try to return more than one objects using return(), it says it is 'deprecated'? So how do I return more than 1 objects back to the parent

[R] tklistbox...

2006-12-12 Thread Jonne Zutt
Hi Rita, This is the option you are looking for: Command-Line Name: -exportselection Database Name: exportSelection Database Class: ExportSelection Specifies whether or not a selection in the widget should also be the X selection. The value may have any of the forms accepted by

[R] greatest common substring

2006-11-14 Thread Jonne Zutt
Dear R-members, Suppose I have a vector with the following strings: V = c(Welfare_Group_1024, Welfare_Group_1536, Welfare_Group_160) I want to 'automatically generate a nice y-axis label for this data. A good candidate is something close to Welfare Group. Is there an easy way to

[R] OT: RBanking

2006-08-08 Thread Jonne
://rbanking.sourceforge.net (thereafter you would need to install several dependencies like BWidgets and tablelist. It would be great if there's a group of people who would slowly like to further develop this, like myself. Any help is appreciated :) Jonne. __ R

[R] 3d cube with labels along axes

2005-09-01 Thread jonne
, intermediate, severe ? x - seq(0, 100, length=10) #x - c(no, light, intermediate, severe) y - x f - function(x,y) { numeric(length=100) + 5 } z - outer(x, y, f) P - persp(x, y, z, theta=30, phi=30, zlim=c(-10,10), ticktype=detailed) text3d(0, 0, -10, Hello world, P) Thanks in advance, Jonne

[R] mva :: prcomp

2004-03-17 Thread Jonne Zutt
as a reference, and help(prcomp/princomp) of course. Thanks for any help! Jonne. # Read a table dir = ... file = ... # huge file, 12 Mb stats = read.table(paste(dir, file, sep=), header=TRUE) # Select several columns data = subset(stats, select = c(sum.delivery.penalty

[R] parsing numbers from a string

2004-02-08 Thread Jonne Zutt
a vector containing [0+74.4/2, 74.4+149/2, ...etc] But I don't know how to parse these strings. Does anyone know how to do this, or maybe is there a simpler way? Thanks in advance, Jonne. __ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch