Hi, I've been learning how to use R TclTk in Windows over the last few months. I have recently put together a collection of examples of some common widgets and their corresponding R code, at http://bioinf.wehi.edu.au/~wettenhall/RTclTkExamples/ I would be interested in any feedback - Is it useful? Does it contain any significant errors or bad coding style? Does anyone else want to contribute similar examples with screenshots? Regards, James -------------------------------------------------------------------------- James Wettenhall Tel: (+61 3) 9345 2629 Division of Genetics and Bioinformatics Fax: (+61 3) 9347 0852 The Walter & Eliza Hall Institute E-mail: wettenhall at wehi.edu.au of Medical Research, Mobile: (+61 / 0 ) 438 527 921 1G Royal Parade, Parkville, Vic 3050, Australia http://www.wehi.edu.au
many thanks for this contribution, perhaps i add in near future some snippets with your starting points! ..here is one simple, but nice for anybody works often with spss-data. regards,christian getfile <- function() { name <- tclvalue(tkgetOpenFile(filetypes="{{SPSS Files} {.sav}} {{All files} *}")) if (name=="") return; zz <- read.spss(name,use.value.label=T,to.data.frame=T) assign("myData",zz,envir=.GlobalEnv) } tt <- tktoplevel() button.widget <- tkbutton(tt,text="Select SPSS File",command=getfile) tkpack(button.widget)> Hi, > > I've been learning how to use R TclTk in Windows over the last > few months. > > I have recently put together a collection of examples of > some common widgets and their corresponding R code, at > > http://bioinf.wehi.edu.au/~wettenhall/RTclTkExamples/ > > I would be interested in any feedback - Is it useful? Does it > contain any significant errors or bad coding style? Does anyone > else want to contribute similar examples with screenshots? > > Regards, > James > > -------------------------------------------------------------------------- > James Wettenhall Tel: (+61 3) 9345 2629 > Division of Genetics and Bioinformatics Fax: (+61 3) 9347 0852 > The Walter & Eliza Hall Institute E-mail: wettenhall at wehi.edu.au > of Medical Research, Mobile: (+61 / 0 ) 438 527 921 > 1G Royal Parade, > Parkville, Vic 3050, Australia > http://www.wehi.edu.au > > ______________________________________________ > R-help at stat.math.ethz.ch mailing list > https://www.stat.math.ethz.ch/mailman/listinfo/r-help
James Wettenhall <wettenhall at wehi.edu.au> writes:> Hi, > > I've been learning how to use R TclTk in Windows over the last > few months. > > I have recently put together a collection of examples of > some common widgets and their corresponding R code, at > > http://bioinf.wehi.edu.au/~wettenhall/RTclTkExamples/ > > I would be interested in any feedback - Is it useful? Does it > contain any significant errors or bad coding style? Does anyone > else want to contribute similar examples with screenshots?Just a few notes: * The tkscript example seems to have lost all indentation, and I think that the info relating to 1.6.0 can be safely lost by now. * Tktable can be handled more easily using callbacks in R-1.7.x. I have an example somewhere on the laptop, I think. Interfacing to Tcl arrays is quite a pain as I'm sure you already found out; something I hope to straighten out in the future. * You're describing the pack manager as superseded by the grid manager, which I think is not quite right. Both are useful in different contexts; some layouts are really awkward to lay out on a grid, so knowing the pack manager can pay off. Re. examples and screenshots, you might be better off just taking examples and doing your own screenshots. Things get more consistent that way. A few examples of how things look like in the Linux interface might be useful, though (maybe Aqua too, anyone?) -- O__ ---- Peter Dalgaard Blegdamsvej 3 c/ /'_ --- Dept. of Biostatistics 2200 Cph. N (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907
Great Examples!! I was looking for exactly some exaples like you did. Thanks a lot (I haven't yet study the code) Thomas Untern?hrer E-Mail: thomas.unternaehrer at zhwin.ch Institut f?r Datenanalyse und Prozessdesign Tel: 052/ 267 7813 Z?rcher Hochschule Winterthur Fax: 052/ 268 7813 Technopark / J?gerstrasse 2 Postfach CH-8400 Winterthur http://www.idp.zhwin.ch