[Rd] Reference: A Legal Issues Primer for Open Source and Free Software Projects
FYI, I found the following to give a useful introduction to what copyright/left is, the ideas behind open-source licenses, and more: Fontana R. et al. 2008. A Legal Issues Primer for Open Source and Free Software Projects. Version 1.5. Software Freedom Law Center, February 14, 2008. URL: http://www.softwarefreedom.org/resources/2008/foss-primer.html /Henrik __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
[Rd] minor bug and patch: attr(x, "names")<-y when y is a pairlist (PR#10807)
Full_Name: John Brzustowski Version: R-devel trunk and R 2.4.0 OS: linux Submission from: (NULL) (76.10.152.79) # Bug: > x<-1:3 > attr(x, "names")<-pairlist("a", "b", "c") > x a a a 1 2 3 # Note that the simpler alternative does work: > names(x)<-pairlist("a", "b", "c") > x a b c 1 2 3 # After applying the patch: > x<-1:3 > attr(x, "names")<-pairlist("a", "b", "c") > x a b c 1 2 3 # The problem is in src/main/attrib.c: namesgets(), where # the pointer to the pairlist of names is not advanced. # Here is a simple patch against R-devel trunk. A cleaner # but more complicated approach would be # to refactor namesgets() and do_namesgets(). # # Note that the name list need not be as long as the LHS, # because subsequent code pads the name list with NAs, if needed. Index: trunk/src/main/attrib.c === --- trunk/src/main/attrib.c (revision 44547) +++ trunk/src/main/attrib.c (working copy) @@ -681,7 +681,7 @@ SEXP namesgets(SEXP vec, SEXP val) { int i; -SEXP s, rval; +SEXP s, rval, tval; PROTECT(vec); PROTECT(val); @@ -695,8 +695,8 @@ else { rval = allocVector(STRSXP, length(vec)); PROTECT(rval); - for (i = 0; i < length(vec); i++) { - s = coerceVector(CAR(val), STRSXP); + for (i = 0, tval=val; i < length(vec) && tval != R_NilValue; i++, tval=CDR(tval)) { + s = coerceVector(CAR(tval), STRSXP); SET_STRING_ELT(rval, i, STRING_ELT(s, 0)); } UNPROTECT(1); __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
[Rd] allow NAs in upper tri for eigen(x,symmetric=TRUE)?
Thanks for acting on my original quibble; I had never questioned whether the diagonal was part of the lower triangle. However, I'm afraid I now have another related quibble. Seeing as ?eigen says that if(symmetric) 'only its lower triangle is used', it's seems a bit unfair of it to complain when there are NAs in the upper triangle. For example, when computing a covariance/distance matrix between a large number of individuals, one might be tempted to only compute the lower.tri values and leave the upper.tri NA. Do you see any justification for changing eigen() along the lines of will.use <- if(symmetric) lower.tri(x, diag=TRUE) else TRUE if (any(!is.finite(x[will.use]))) stop("infinite or missing values in 'x'") ? Thanks, Dan On Thu, Nov 29, 2007 at 05:46:38PM +0100, Martin Maechler wrote: > > "DD" == Dan Davison <[EMAIL PROTECTED]> > > on Thu, 29 Nov 2007 11:34:18 + writes: > > DD> from ?eigen > DD> symmetric: if 'TRUE', the matrix is assumed to be symmetric (or > DD> Hermitian if complex) and only its lower triangle is used. If > DD> 'symmetric' is not specified, the matrix is inspected for > DD> symmetry. > > > DD> I think that could mislead a naive reader as it suggests that, with > symmetric=TRUE, > DD> the result of eigen() (vectors and values) depends only on the > lower-triangular values, > DD> and thus not on the values on the diagonal (that's not true for the > eigenvalues). > > Well, that all depends on what you think when you read > "lower triangle". > > For many of us, this can include the diagonal or not, and we > don't know if it is not specified further. > > ?lower.tri -- shows the option to include the diagonal. > > Consequently, I'd suggest to replace > >"only its lower triangle is used" > with "only its lower triangle (diagonal included) is used" > > Martin Maechler, ETH Zurich > > DD> I suggest that changing it to > > DD> "... and only its lower triangle is used when computing the > eigenvectors." > > DD> would be more accurate, perhaps even with a reminder about the trace > - sum of eigenvalues > DD> relationship. > > DD> Dan > > DD> __ > DD> R-devel@r-project.org mailing list > DD> https://stat.ethz.ch/mailman/listinfo/r-devel __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
[Rd] DNAcopy package output data
Hello R Developers I am using DNACopy package http://bioconductor.org/packages/1.9/bioc/html/DNAcopy.html I am not able to figure out how to (if at all possible) to modify output format, namely, I am getting the following: "ID""chrom" "loc.start" "loc.end" "num.mark" "seg.mean" Is it a way to get also median and standard deviation? Thanks in advance, Vlad -- *** Dr. Vladimir Makarov Instructor, Computer Science Department School of Computer Science and Information Systems Pace University 163 Williams Street New York, NY 10038 Phone: (212) 639 - 7422 eMail: [EMAIL PROTECTED] http://matrix.csis.pace.edu/~vmakarov/ *** The information contained in this email message and any files transmitted with it are confidential and intended solely for the use by the individual(s) originally addressed. Please disregard and delete this email if you are not the intended recipient. __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Rd] Bug using X11 on mac osx (for jpeg or png creation) (PR#10800)
That being documented behavior, I still find the documented behavior somewhat inconvenient: the fact that some code I interactively tested does not run in the same way in batch mode. My own solution involves running a separate semi-permanent Xvfb process and let R CMD BATCH uses the virtual X server; but I do wish that jpeg()/png() would work the same way - or at least in a similiar way transparently with or without X11. I know of the bitmap(), but my wish would be to *using the exact same functions* in interactive/batch mode. bitmap() doesn't quite work the same as jpeg()/png(), nor is Xvfb gives identical result to the console X server (due to resolution/dpi configuation differences). The thing is, WYSIWYG, matching font sizes relative to plots, etc, can only be done visually, and then everything changes in batch mode... so in the end, I do pdf's in interactive sessions and look at them with a separate viewer (pdf/ps not dependent on X11), and if there are too many dots, etc I rasterize it through ghostscript to keep the file size down. None of these are too convenient. Prof Brian Ripley wrote: > On Tue, 19 Feb 2008, Benilton Carvalho wrote: > >> It's not a bug and it is my understanding that it's documented. >> >> From the man page on jpeg: >> >> They may not be usable unless the X11 display is available to the owner of >> the R process. >> >> and later: >> >>'bitmap' provides an alternative way to generate PNG and JPEG >>plots that does not depend on accessing the X11 display but does >>depend on having GhostScript installed. (Devices 'GDD' in CRAN >>package 'GDD' and 'CairoJPEG' / 'CairoPNG' in CRAN package 'Cairo' >>are alternatives using several other additional pieces of >>software.) >> >> So, the idea is to replace your jpeg() call by bitmap() (with the >> appropriate >> "type" argument. > > He may have a slightly different version: he seems to have access to X11 > but no fonts available. That is not an R bug: it may well be an Apple > bug (we've seen similar things on Ubuntu, and there are lots of known > issues with Apple's X11). > > [BTW: it is better to report the exact French messages: we can look them > up in the translations database. Or even better, start R with LANGUAGE=en > and report the English message. I suspect this one is > > could not find any X11 fonts\nCheck that the Font Path is correct. > > as that seems the closest match. And if so the advice in that English > message is the key to solving this.] > >> b >> >> On Feb 19, 2008, at 8:25 AM, [EMAIL PROTECTED] wrote: >> >>> Full_Name: Stephane Bonneaud >>> Version: 2.6.2 >>> OS: OSX - Leopard 10.5.2 >>> Submission from: (NULL) (195.221.233.130) >>> >>> >>> Hello, >>> >>> I have a R code file containing the following code: >>> >>> --- >>> # This code is in r2jpg.r >>> # myData is filled here with some data from a file >>> jpeg(filename="test.jpg",width=960,height=720,pointsize=16,quality=100) >>> plot(myData,xlab="anything", ylab="whatever",type="b",col="red", lwd=4) >>> dev.off() >>> --- >>> >>> I executed this code within both the R GUI and the command line. When >>> launched >>> through the R GUI (Mac OS X Cocoa GUI - GUI 1.22-devel (4844) (4844)), >>> everything works just fine. The JPEG file is generated just I want. Great! >>> The problem is when I try to execute the code through the command line in >>> Terminal (OSX). >>> I execute my code using the following command : >>> cat r2jpg.r | R --silent --no-restore --no-save >>> >>> And I get the following error: >>> jpeg(filename="test.jpg",width=960,height=720,pointsize=16,quality=100) >>> can't find X11 font >>> Error in X11(paste("jpeg::", quality, ":", filename, sep = ""), width, : >>> impossible to start the peripheral JPEG >>> Calls: jpeg >>> >>> (Sorry, I translated the error messages from french so it might be a little >>> different in english. If needed I can print it in english though) >>> >>> I saw that several persons had this problem, but did not find any proper >>> solution. Therefore, I tried to launch my command from xterm (still in OSX) >>> and >>> not in Terminal, and it worked. There is definitely an issue with R getting >>> the >>> proper environment variables for X11 or something like that when launched >>> from >>> the command line in Terminal. >>> When you launch the GUI, OSX detects it will need X11 (or something like >>> this >>> :b), therefore all proper env variables are charged. From xterm, obviously >>> the >>> proper env variables are set. >>> >>> How could R tell OSX to link with X11 when launched from command line in >>> Terminal? >>> >>> PS: sorry, it might be a leopard bug, but I thought somebody could be >>> interested >>> in the R community. And maybe R developers might actually be able to do >>> something. >>> >>> __ >>> R-devel@r-project.org mailing list >>> https://stat.ethz.ch/mailman/listinfo/r-devel >
Re: [Rd] DNAcopy package output data
This is a Bioconductor package, so please address questions to the Bioconductor list (instructions at http://www.bioconductor.org/docs/mailList.html). This is not a question related to 'development' but to use, so you do not need to ask on the '-devel' mailing list. Do you mean the result of 'segment'? It's always helpful to provide a reproducible (e.g., using the example data provided with the package) example! I think the easy answer to your question is 'no', there are no documented arguments influencing how statistics on the segment are calculated. The longer answer is 'yes', since the source of the function is readily available (typing > segment ) and the segment boundaries are returned and hence other statistics can be calculated by the user. Hope that helps, Martin "Vladmir Makarov" <[EMAIL PROTECTED]> writes: > Hello R Developers > > I am using DNACopy package > http://bioconductor.org/packages/1.9/bioc/html/DNAcopy.html > > I am not able to figure out how to (if at all possible) to modify > output format, namely, I am getting the following: > "ID" "chrom" "loc.start" "loc.end" "num.mark" "seg.mean" > > Is it a way to get also median and standard deviation? > > Thanks in advance, > Vlad > > -- > *** > Dr. Vladimir Makarov > Instructor, Computer Science Department > School of Computer Science and Information Systems > Pace University > 163 Williams Street > New York, NY 10038 > Phone: (212) 639 - 7422 > eMail: [EMAIL PROTECTED] > http://matrix.csis.pace.edu/~vmakarov/ > > *** > > > The information contained in this email message and any files > transmitted with it are confidential and intended solely for the use > by the individual(s) originally addressed. Please disregard and delete > this email if you are not the intended recipient. > > > __ > R-devel@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-devel -- Martin Morgan Computational Biology / Fred Hutchinson Cancer Research Center 1100 Fairview Ave. N. PO Box 19024 Seattle, WA 98109 Location: Arnold Building M2 B169 Phone: (206) 667-2793 __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
[Rd] Tcl/Tk extensions
This is a word of warning to those package authors who want to make use of Tcl/Tk extensions. First, please document them in the DESCRIPTION file, in the SystemRequirements field. Second, people have been recommending ActiveTcl. The latest ActiveTcl releases are much smaller, and it seems this is because the extensions are not included so those recommendations will need to be changed. I am contemplating adding a few extensions to the R 2.7.0 Windows distribution -- certainly BWidget and Tktable seem fairly easy to do. The only other Tcl/Tk extensions I have found are Iwidgets, which might not be so easy (it requires itcl and itk) and Img (not easy). (There are some mentioned in packages which I have not found.) There are a number of additional widgets in Tk 8.5 that might be easier to make use of (R 2.7.0 for Windows will ship with Tcl/Tk 8.5.x). Ideally someone who wants to make use of these extensions will volunteer to distribute Windows versions of them -- I expect Duncan Murdoch would be happy to include them in Rtools.exe if the licence conditions allow. -- Brian D. Ripley, [EMAIL PROTECTED] Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UKFax: +44 1865 272595 __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel