Re: [R] Extracting elements from a matrix using a vector containing indices

2013-05-07 Thread Mark Coletti
On Tue, May 7, 2013 at 4:53 AM, peter dalgaard wrote: > > On May 7, 2013, at 06:39 , Mark Coletti wrote: > > > I have a matrix of data that has a corresponding vector of indices. I > > would like to use those indices to extract specific matrix elements into > a > &g

[R] Extracting elements from a matrix using a vector containing indices

2013-05-06 Thread Mark Coletti
I have a matrix of data that has a corresponding vector of indices. I would like to use those indices to extract specific matrix elements into a new vector. In other words, I have an R X C matrix with a corresponding vector of C elements that have numbers mapping into specific elements of the mat

[R] Resolved tklistbox selection problem

2008-05-09 Thread Mark Coletti
Turns out I needed to add "exportselection=0". So: foo.lb <- tklistbox(root, height = 5, selectmode = "extended", exportselection = 0) Got this from: http://tolstoy.newcastle.edu.au/R/e2/help/06/12/6955.html (That's what I get for assuming there'd be no tcl/tk questions on

[R] Odd tcl/tk listbox problem

2008-05-09 Thread Mark Coletti
I get strange behavior when a GUI has more than one list box. Variable selection between the two boxes appears to be mutually exclusive! So, for the contrived example below: library(tcltk) > > root = tktoplevel() > > foo = c("foo","bar", "baz", "quux") > > foo.list <- tclVar() > > tclObj(foo.lis

[R] Attempting to sync x-axis labels with grid lines in lattice bwplot

2008-04-20 Thread Mark Coletti
en realized that there seemed to be no way to get that information to the "scale/at" parameter. Does anyone have any tips for correcting this? I suppose I could cut down the label font size, but that's a bit of an eye straining kludge. Cheers! Mark Coletti ___