[Rd] list.files(recursive=T) does not return directory names

2005-11-25 Thread bill
them. Would adding type = "files","directories","all" to list.files and dir conflict with any plans for R's list.files or dir? Bill Dunlap Insightful Corporation bill at insightful dot com 360-428-8146 "Formerly known as MathSoft

Re: [Rd] Using substitute from inside an S4 method

2006-01-25 Thread bill
if(nchar(x)>n) stop("nchar(x)>n") x.name } x.name <- deparse(substitute(x)) A.character(x, ..., x.name=x.name) } ) This gives a suggestive function name in the error message > A(paste("One",&q

[Rd] supsmu(periodic=TRUE) can crash R by reading before start of array (PR#9502)

2007-02-08 Thread bill
C_IDENTIFICATION=C Search Path: .GlobalEnv, package:stats, package:graphics, package:grDevices, package:utils, package:datasets, package:methods, Autoloads, package:base -------- Bill Dunlap Insightful Corporation bill at insightful dot com 3

[Rd] missing axes in irregular lattice plots (PR#9556)

2007-03-07 Thread bill
the layout(1,n),as.table=T problem by making sure the last plot has x axis tick labels associated with it, just as the last plot always gets y axis tick labels associated with it. ---- Bill Dunlap Insightful Corporation bill at ins

Re: [Rd] R CMD Rdconv drops sections: arguments, seealso, examples (PR#9645)

2007-04-30 Thread bill
On Tue, 10 Apr 2007 [EMAIL PROTECTED] wrote: > I've created a .Rd file (below), then converted that to .sgml using > R CMD Rdconv --type=Ssgm combn.Rd > combn.sgml > The output (shown below) is missing some of the sections: > arguments > seealso > examples > If instead I c

Re: [Rd] R CMD Rdconv drops sections: arguments, seealso, examples (PR#9649)

2007-05-01 Thread bill
On Mon, 30 Apr 2007 [EMAIL PROTECTED] wrote: > On Tue, 10 Apr 2007 [EMAIL PROTECTED] wrote: > > > I've created a .Rd file (below), then converted that to .sgml using > > R CMD Rdconv --type=Ssgm combn.Rd > combn.sgml > > The output (shown below) is missing some of the sections: > > argume

[Rd] write.dcf/read.dcf cycle converts missing entry to "NA" (PR#9796)

2007-07-17 Thread bill
Full_Name: Bill Dunlap Version: 2.5.0 OS: Red Hat Enterprise Linux WS release 3 (Taroon Update 6) Submission from: (NULL) (24.17.60.30) If you read a dcf file with read.dcf(file,fields=c("Field",...)) and the file does not contain the desired field "Field", read.dcf puts a c

Re: [Rd] sequence(c(2, 0, 3)) produces surprising results, would (PR#9813)

2007-07-26 Thread bill
On Thu, 26 Jul 2007 [EMAIL PROTECTED] wrote: > Full_Name: Bill Dunlap > Version: 2.5.0 > OS: Linux > Submission from: (NULL) (70.98.76.47) > > sequence(nvec) is documented to return > the concatenation of seq(nvec[i]), for > i in seq(along=nvec). This produces inconvenien

[Rd] sequence(c(2, 0, 3)) produces surprising results, would like output length to be sum(input) (PR#9811)

2007-07-26 Thread bill
Full_Name: Bill Dunlap Version: 2.5.0 OS: Linux Submission from: (NULL) (70.98.76.47) sequence(nvec) is documented to return the concatenation of seq(nvec[i]), for i in seq(along=nvec). This produces inconvenient (for me) results for 0 inputs. > sequence(c(2,0,3)) # would like 1 2 1

Re: [Rd] (PR#9811) sequence(c(2, 0, 3)) produces surprising results,

2007-07-30 Thread bill
dentifies group [1] 1 1 1 1 1 2 2 3 3 3 3 3 3 3 > sequence(c(5,2,7)) # which in group [1] 1 2 3 4 5 1 2 1 2 3 4 5 6 7 ---- Bill Dunlap Insightful Corporation bill at insightful dot com 360-428-8146 "All statement

[Rd] *.Rd file: space after topic in "\alias{topic }" should be ignored (PR#9914)

2007-09-17 Thread bill
Full_Name: Bill Dunlap Version: R version 2.6.0 Under development (unstable) (2007-07-26 r42329) OS: Linux Submission from: (NULL) (24.16.101.199) If a *.Rd file has an \alias{topic } with a space between 'topic' and the closing '}' then the space is copied to the help/A

Re: [Rd] *.Rd file: space after topic in "\alias{topic }" should be (PR#9915)

2007-09-17 Thread bill
On Mon, 17 Sep 2007 [EMAIL PROTECTED] wrote: > Full_Name: Bill Dunlap > Version: R version 2.6.0 Under development (unstable) (2007-07-26 r42329) > OS: Linux > Submission from: (NULL) (24.16.101.199) > > If a *.Rd file has an \alias{topic } with a space > between 'topic

[Rd] codetools::checkUsage should ignore expression in Quote(expr) (PR#10719)

2008-02-06 Thread bill
Full_Name: Bill Dunlap Version: R version 2.7.0 Under development (unstable) (2008-02-05 r44340) OS: Linux Submission from: (NULL) (76.28.245.14) codetools::checkUsage() should treat the Quote() function just as it does the quote() and expression() functions: by ignoring its argument. Currently

[Rd] unix.time() scoping problem (PR#11169)

2008-04-14 Thread bill
Full_Name: Bill Dunlap Version: 2.8.0 Under development (unstable) svn 45325 OS: Linux Submission from: (NULL) (76.28.245.14) It is difficult to write wrapper functions for unix.time(expr) because it uses the idiom expr <- substitute(expr) eval(expr, envir=sys.parent()) to evaluate

[Rd] non-digits in svnversion output mess up windows build if USE_SVNVERSION=yes (PR#11339)

2008-04-29 Thread bill
Full_Name: Bill Dunlap Version: 2.8.0dev OS: Windows XP Submission from: (NULL) (70.98.76.47) I tried for the first time to build R from source on Windows, where I got the source code via svn. Per the Installation and Administration manual, I altered src\gnuwin32\MkRules so it had the the

Re: [Rd] non-digits in svnversion output mess up windows build if (PR#11341)

2008-04-29 Thread bill
then we could check the disribution by checking that !is.na(as.integer(svn$"svn rev")). It might also be nice to include the output of 'svn diff' in the distribution so a user or tester could see how this version was different than the official one. > On 29/04/2008 2:30 P

[Rd] memory leak in sub("[range]", ...) when #ifndef _LIBC (PR#11946)

2008-08-07 Thread bill
Full_Name: Bill Dunlap Version: R version 2.8.0 Under development (unstable) (2008-07-05 r46037) OS: Linux Submission from: (NULL) (76.28.245.14) valgrind finds some memory leaks in R when I use sub() with a range in the regular expression: % R --debugger=valgrind --debugger-args=--leak-check

[Rd] Rdconv --type=Ssgm drops singleton keywords (PR#9051)

2006-06-30 Thread bill
If an Rd file has only one keyword entry then the Splus sgm file made with Rdconv --type=SSgm has no keyword entries. To reproduce: Use prompt() to make a skeleton help file R> f<-function(x)log(1+x)-log1p(x) R> prompt(f) Created file named 'f.Rd'. Edit the file and move

[Rd] R::Rdconv Rdconv() does not close input file handle (PR#9126)

2006-08-04 Thread bill
Full_Name: Bill Dunlap Version: 2.3.0 OS: Windows XP Submission from: (NULL) (71.121.183.214) If you had an Rd file called "file.Rd" and write a perl script containing print "Before Rdconv: " ; system "/usr/sbin/lsof | grep $USER | grep Rd"; Rdconv(&qu

[Rd] readBin(what="character", n=overcount)->extra "" in result (PR#9361)

2006-11-13 Thread bill
Full_Name: Bill Dunlap Version: 2.4.0 OS: Windows XP Submission from: (NULL) (208.252.71.182) When I use readBin() to read an unknown number of null-terminated strings from a file by supplying an overcount as the n= argument, it appends an empty string to the result. > tf<-tempfile() >

Re: [Rd] readBin(what="character", n=overcount)->extra "" in result (PR#9363)

2006-11-13 Thread bill
On Mon, 13 Nov 2006 [EMAIL PROTECTED] wrote: > When I use readBin() to read an unknown number > of null-terminated strings from a file by supplying > an overcount as the n= argument, it appends an empty > string to the result. > > > tf<-tempfile() > > strings<-c("One","Two","Three") > > writeBin(s

Re: [Rd] rm() deletes 'c' if c('a','b') is the argument (PR#9399)

2006-11-29 Thread bill
d patching up in various ways to work in all situation (e.g., library's character.only=TRUE argument and the complicated code in help to see what the topic really is). Perhaps rm() should be deprecated in favor of remove(), which uses standard S syntax rules. -

[Rd] MacOS 10.4 gcc-4.0 and libcc_dynamic

2005-07-05 Thread Bill Northcott
the not too distant future gfortran will become part of the Xcode packages. Bill Northcott __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel

[Rd] Building R sources on Windows

2005-07-13 Thread Bill Northcott
copy of the makeinfo binary to save the trouble of building it, please email me. One final note: If you install the MinGW Msys-DTK rename the perl binaries such as perl.exe which it provides. Otherwise they will be used instead of the ActiveStat

[Rd] Problems in rgl on MacOS X

2005-07-19 Thread Bill Northcott
L_MAX_TEXTURE_SIZE, (GLint*) &maxSize); but this generates warnings about signed and unsigned further down scene.cpp. The resulting code works but it is clearly not right. I can't find an email address for the maintainer and his web site seems to be off the air just now. Bill Northcott __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel

Re: [Rd] call fortran in R

2005-08-05 Thread Bill Northcott
environment in which the R binary was built. You can always go back to gcc-4.0 with 'sudo gcc_select 4.0'. Bill Northcott __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel

[Rd] NextMethod causes R 2.2.0 to crash (PR#8416)

2005-12-20 Thread Bill . Venables
s(m) [1] "Date" > julian(m) [1] 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 attr(,"origin") [1] "1970-01-01" > m <- as.character(m) > class(m) [1] "character" > julian(m) < R crashes> --please do not edit the information below--

[Rd] initialize expression in 'quasi' (PR#8486)

2006-01-16 Thread Bill . Venables
at you get above when mustart is supplied. The changes cannot affect performance with any other variance functions and with this variance function should only make things better, but it just _might_ make things work worse in extreme and unusual cases. I have not found one, though. Bill Venables.=20

Re: [Rd] tools::package_dependencies problems

2020-10-16 Thread Bill Dunlap
Have you tried using the 'db' argument to tools::package_dependencies? rbind the common columns of installed.packages() and available.packages() and use that as the package database. installed <- installed.packages() available <- available.packages() commonCols <- intersect(colnames(ins

[Rd] (no subject)

2020-11-04 Thread Bill Dunlap
Hi All, I am no longer with TIBCO and hope to be able to contribute more directly to R now. It will take a little while to set up a build environment and to start working on some bugzilla issues. -Bill Dunlap williamwdun...@gmail.com [[alternative HTML version deleted

[Rd] formatting issue with gcc 9.3.0 on Ubuntu on WSL2

2020-11-17 Thread Bill Dunlap
15" "9.508000e-15" "9.838000e-15" [7] "9.899000e-15" "9.934000e-15" "9.995000e-15" > str(grep(value=TRUE, "0e", vapply((1+(0:1)/1000)*1e-14, deparse, ""))) chr [1:295] "8.0020

Re: [Rd] formatting issue with gcc 9.3.0 on Ubuntu on WSL2

2020-11-18 Thread Bill Dunlap
untu 2' in Poweshell fixed the problem. This also fixed one of my test C programs: '1.0L + 1e-60L > 1.0L' was true if I compiled with gcc -O but false with no optimization. On Wed, Nov 18, 2020 at 3:56 AM Iñaki Ucar wrote: > On Wed, 18 Nov 2020 at 10:26, Tomas Kalibera &

Re: [Rd] return (x+1) * 1000

2020-11-20 Thread Bill Dunlap
Perhaps the parser should warn if you use return() at all. It is rarely needed and is akin to the evil 'GOTO' statement in that it makes the flow of control less obvious to the reader. -Bill On Fri, Nov 20, 2020 at 2:37 PM Mateo Obregón wrote: > I'm not thinking of complicat

Re: [Rd] .Internal(quit(...)): system call failed: Cannot allocate memory

2020-11-23 Thread Bill Dunlap
t=saveact@entry=SA_NOSAVE, status=status@entry=0, runLast=) at system.c:87 #4 0x556cc85e in do_quit (call=, op=, args=0x57813f90, rho=) at main.c:1393 -Bill On Mon, Nov 23, 2020 at 3:15 AM Tomas Kalibera wrote: > On 11/21/20 6:51 PM, Jan Gorecki wrote: > > Dear R-develope

Re: [Rd] all.equal applied to function closures

2020-11-30 Thread Bill Dunlap
To make the comparison more complete, all.equal.environment could compare the parents of the target and current environments. That would have to be recursive but could stop at the first 'top level environment' (the global, empty, or a package-related environment generally) and use identical there.

Re: [Rd] all.equal applied to function closures

2020-12-01 Thread Bill Dunlap
, parent=list2env(list(p=1.5), parent=new.env(parent=baseenv( > base::all.equal.environment(E1,E3) [1] TRUE > globalenv()$all.equal.environment(E1,E3) [1] " Component “p”: Mean relative difference: 0.1538462" [2] " target is and current is " On Tue, Dec 1, 2020 at 1

Re: [Rd] [R/S-PLUS] [EXTERNAL] Re: [External] anonymous functions

2020-12-07 Thread Bill Dunlap
One advantage of the new pipe operator over magrittr's is that the former works with substitute(). > f <- function(x, xlab=deparse1(substitute(x))) paste(sep="", xlab, ": ", paste(collapse=", ",x)) > 2^(1:4) |> f() [1] "2^(1:4): 2, 4, 8, 16" > 2^(1:4) %>% f() [1] ".: 2, 4, 8, 16" This is because

Re: [Rd] the pipe |> and line breaks in pipelines

2020-12-09 Thread Bill Dunlap
uot;debug"))) before the eval() or assignment to make these do nothing to make it easy to turn debugging on and off with options(debug=TRUE/FALSE). -Bill On Wed, Dec 9, 2020 at 1:58 PM Timothy Goodman wrote: > > On Wed, Dec 9, 2020 at 1:03 PM Duncan Murdoch > wrote: Then I could

Re: [Rd] From .Fortran to .Call?

2020-12-19 Thread Bill Dunlap
To make C prototypes for routines defined in a *.f file you can use gfortran's -fc-prototypes-external flag. You still have to convert 'name_' to 'F77_NAME(name). bill@Bill-T490:~/packages/quantreg/src$ gfortran -fc-prototypes-external -fsyntax-only boot.f ... [elided d

Re: [Rd] From .Fortran to .Call?

2020-12-31 Thread Bill Dunlap
. -Bill On Wed, Dec 23, 2020 at 8:27 AM Bill Dunlap wrote: >As the proverbial naive R (ab)user I’m left wondering: > > o if I updated my quantreg_init.c file in accordance with Bill’s > suggestion could I > then simply change my .Fortran calls to .Call?

Re: [Rd] From .Fortran to .Call?

2020-12-31 Thread Bill Dunlap
rs to R objects), never the double* or the like that .Fortran expects. -Bill On Wed, Dec 23, 2020 at 3:58 AM Koenker, Roger W wrote: > Thanks to all and best wishes for a better 2021. > > Unfortunately I remain somewhat confused: > > o Bill reveals an elegant way to get

Re: [Rd] [External] brief update on the pipe operator in R-devel

2021-01-12 Thread Bill Dunlap
l turn the |> and => into an ordinary looking function call so deparsing is irrelevant. > deparse(quote(x |> tmp => f(7,arg2=tmp))) [1] "f(7, arg2 = x)" -Bill On Tue, Jan 12, 2021 at 12:01 PM Dirk Eddelbuettel wrote: > > On 12 January 2021 at 20:38, Iñaki

Re: [Rd] [External] brief update on the pipe operator in R-devel

2021-01-13 Thread Bill Dunlap
{ if (!is.list(expr)) { expr <- as.list(expr) } nms <- names(expr) for (i in seq_along(expr)) { str.language(expr[[i]], name=nms[[i]], indent = indent + 1) } } invisible(expr) } On Tue, Jan 12, 2021 at 1:16 P

Re: [Rd] brief update on the pipe operator in R-devel

2021-01-15 Thread Bill Dunlap
If 3 |> x => f(x, y=x) were allowed then I think that runif(1) |> x => f(x, y=x) be parsed as f(runif(1), y=runif(1)) so runif(1) would be evaluated twice, leading to incorrect results from f(). -Bill On Fri, Jan 15, 2021 at 2:16 PM Avi Gross via R-devel wro

Re: [Rd] Corrupt internal row names when creating a data.frame with `attributes<-`

2021-02-16 Thread Bill Dunlap
> rownames(as.matrix(dPos)) [1] "1" "2" "3" > rownames(as.matrix(dNeg)) NULL -Bill On Tue, Feb 16, 2021 at 11:06 AM Kevin Ushey wrote: > > Strictly speaking, I don't think this is a "corrupt" representation, > given that any APIs u

Re: [Rd] Potential improvements of ave?

2021-03-16 Thread Bill Dunlap
Your proposed change (roughly, replacing interaction() by unique(paste())) slows down ave() considerably when there are long columns with lots of repeated rows. I think that interaction(drop=TRUE, ...) can be changed to use less memory and be faster by making a separate branch for drop=TRUE that u

Re: [Rd] Surprising behavior when using the reference class with the dollar symbol

2021-03-27 Thread Bill Dunlap
<- "A" > `$`(L, i) NULL The 2nd argument is treated as a symbol and is never evaluated. If it is given as a string literal then it is converted to a symbol - that is a holdover from the old days before backticks could be used to make symbol literals for symbols that included odd th

Re: [Rd] base R pipe documentation

2021-05-18 Thread Bill Dunlap
help(`|>`) does mention magrittr's pipe operator so the user can compare and contrast them. -Bill On Mon, May 17, 2021 at 10:20 AM Ben Bolker wrote: >As of right now, as far as I can tell, the documentation for the new > native |> pipe still says that it's experimen

Re: [Rd] Should last default to .Machine$integer.max-1 for substring()

2021-06-21 Thread Bill Dunlap
use Inf as the default? Then the following would give 4 identical results with no warning: > substring("abcde", 3, c(10, 2^31-1, 2^31, Inf)) [1] "cde" "cde" NANA Warning message: In substring("abcde", 3, c(10, 2^31 - 1, 2^31, Inf)) : NAs introduced

Re: [Rd] ALTREP ALTINTEGER_SUM/MIN/MAX Return Value and Behavior

2021-06-29 Thread Bill Dunlap
am) [1] FALSE > .Call("is_altrep", amn) [1] FALSE where is_altrep() is defined by the following C code: #include #include SEXP is_altrep(SEXP x) { return Rf_ScalarLogical(ALTREP(x)); } -Bill On Tue, Jun 29, 2021 at 8:03 AM Sebastian Martin Krantz < sebastian.kra...@graduate

Re: [Rd] [R-pkg-devel] Tracking down inconsistent errors and notes across operating systems

2021-07-22 Thread Bill Dunlap
‘s_object’ 7 | static s_object* obj = NULL; |^~~~ On Thu, Jul 22, 2021 at 10:18 AM Bill Dunlap wrote: > I think the problem with RPostgreSQL/sec/RS-DBI.c comes from some changes > to Defn.h and Rinternals.h in RHOME/include that Luke made recently > (2021-07-20, s

Re: [Rd] Inconsistent is.list results on 'by' objects

2021-11-16 Thread Bill Dunlap
Try adding simplify=FALSE to the call to by(). -Bill On Tue, Nov 16, 2021 at 4:04 AM Ofek Shilon wrote: > Take this toy code: > df <- data.frame(a=seq(10), b=rep(1:2, 5)) > df.empty <- subset(df, a>10) > byy <- by(data=df, INDICES=df$b, FUN=functi

Re: [Rd] How is the environment variable "R_USER" defined?

2021-11-22 Thread Bill Dunlap
Is your C:\Users\yourname\Documents linked to OneDrive (either by your choice or by some administrator setting a group policy)? If so, ou could unlink it using OneDrive's settings dialog. Or you could set R_USER to avoid using ...\Documents. -Bill On Mon, Nov 22, 2021 at 8:47 AM Jiefei

Re: [Rd] string concatenation operator (revisited)

2021-12-06 Thread Bill Dunlap
Should paste0(character(0), c("a","b")) give character(0)? There is a fair bit of code that assumes that paste("X",NULL) gives "X" but c(1,2)+NULL gives numeric(0). -Bill On Mon, Dec 6, 2021 at 1:32 PM Duncan Murdoch wrote: > On 06/12/2021 4:21 p.m.,

Re: [Rd] string concatenation operator (revisited)

2021-12-06 Thread Bill Dunlap
>I think a lot of these things ultimately mean that if there were to be a string >concatenation operator, it probably shouldn't have behavior identical to >paste0. Was that what you were getting at as well, Bill? Yes. On Mon, Dec 6, 2021 at 4:21 PM Gabriel Becker wrote: > A

Re: [Rd] New R version - Issue with as.vector coercion on data.frame

2022-05-02 Thread Bill Dunlap
4.1.2's as.vector(aDataFrame) did. I think that as.vector() is a function that few people should use. It has almost nothing to do with with the notion of a vector in math or physics. -Bill On Mon, May 2, 2022 at 2:19 AM Marc Weibel wrote: > Hi > > I recently upgraded to the l

Re: [Rd] Parser bug? A comma too much.

2022-09-16 Thread Bill Dunlap
> By putting in the comma, unless I am mistaken, you are effectively > saying the second element is NULL, which is how it's naturally > defined. No, in f(x,) the second argument is missing, not NULL. -Bill On Fri, Sep 16, 2022 at 7:43 AM Avraham Adler wrote: > That may act

Re: [Rd] Lazy-evaluate elements wrapped with invisible

2022-10-28 Thread Bill Dunlap
m_x'\n"); sum(x)}) +environment() + } > fx <- f(1:10) > date() [1] "Fri Oct 28 14:22:12 2022" > Sys.sleep(2) > fx$eval_date Evaluating 'date' [1] "Fri Oct 28 14:22:24 2022" > Sys.sleep(2) > fx$eval_date [1] "Fri Oct 28 14:22:24

Re: [Rd] Lazy-evaluate elements wrapped with invisible

2022-10-29 Thread Bill Dunlap
ent of a list should be considered garbage if not 'immediately' extracted from a list? Could you show a few usage cases? -Bill On Fri, Oct 28, 2022 at 7:41 PM Dipterix Wang wrote: > > This is not quite true. The value, even when invisible, is captured by > .Last.value, and &

Re: [Rd] Potential bug in fitted.nls

2023-01-26 Thread Bill Dunlap
Doesn't nls() expect that the lengths of vectors on both sides of the formula match (if both are supplied)? Perhaps it should check for that. -Bill On Thu, Jan 26, 2023 at 12:17 AM Dave Armstrong wrote: > Dear Colleagues, > > I recently answered [this question]() on Stac

Re: [Rd] tab-complete for non-syntactic names could attempt backtick-wrapping

2023-03-02 Thread Bill Dunlap
t;)), typeof, "") [1] "symbol""symbol""character" > vapply(as.list(quote(list$'component')), typeof, "") [1] "symbol""symbol""character" Single and double quoted character sequences do parse to t

Re: [Rd] WISH: Optional mechanism preventing var <<- value from assigning non-existing variable

2023-03-19 Thread Bill Dunlap
Why should it make an exception for cases where the about-to-be-assigned-to name is present in the global environment? I think it should warn or give an error if the altered variable is in any environment on the search list. -Bill On Sun, Mar 19, 2023 at 10:54 AM Duncan Murdoch wrote: >

Re: [Rd] xyTable(x,y) versus table(x,y) with NAs

2023-04-25 Thread Bill Dunlap
, NA, 3) > str(xyTable(x,y)) List of 3 $ x : num [1:5] 1 2 2 5 6 $ y : num [1:5] 2 2 4 NA 3 $ number: int [1:5] 2 1 1 1 1 table() does not use this logic, as one NA in a vector would make all the counts NA. Should xyTable have a way to handle NAs the way table() does? -Bill On

Re: [Rd] range() for Date and POSIXct could respect `finite = TRUE`

2023-05-11 Thread Bill Dunlap
n and max for the class instead of one that just said they were -Inf and Inf or not. -Bill On Thu, May 11, 2023 at 1:49 AM Martin Maechler wrote: > >>>>> Davis Vaughan > >>>>> on Tue, 9 May 2023 09:49:41 -0400 writes: > > > It seems like the ma

Re: [Rd] New behavior when running script in package directory?

2023-06-21 Thread Bill Dunlap
If ./Rprofile is not present and ~/.Rprofile is present then R will run the latter at startup. Do you have a ~/.Rprofile that defines a ss() function? -Bill On Wed, Jun 21, 2023 at 8:50 AM Dominick Samperi wrote: > Thanks, I checked for .Rprofile and .RData files. They are not present.

Re: [Rd] Concerns with SVD -- and the Matrix Exponential

2023-08-16 Thread Bill Dunlap
. Can you state your definition of the SVD and prove (or outline a proof of) that last statement? -Bill On Wed, Aug 16, 2023 at 3:47 AM Durga Prasad G me14d059 < me14d...@smail.iitm.ac.in> wrote: > Dear Martin, I am getting different responses from different officials of > R-Softwar

Re: [Rd] capture error messages from loading shared objects

2023-11-28 Thread Bill Dunlap
If you would like to save the error message instead of suppressing it, you can use tryCatch(message=function(e)e, ...). -BIll On Tue, Nov 28, 2023 at 3:55 AM Adrian Dusa wrote: > Once again, Ivan, many thanks. > Yes, that does solve it. > Best wishes, > Adrian > > On Tue,

Re: [Rd] Difficult debug

2024-02-07 Thread Bill Dunlap
help track down memory problems. -Bill On Wed, Feb 7, 2024 at 12:03 PM Therneau, Terry M., Ph.D. via R-devel < r-devel@r-project.org> wrote: > I've hit a roadblock debugging a new update to the survival package. I > do debugging in > a developement envinment, i.e. I don&#x

Re: [Rd] Difficult debug

2024-02-07 Thread Bill Dunlap
rts memory misuse and | >>> you can inspect variables, etc., where an error occurs. | >>> You can check for memory leaks from gdb with | >>>(gdb) monitor leak_check full | >>> | >>> -Bill You can use ^C to get the gdb prompt, to, say, set a bre

Re: [Rd] [External] Re: capture "->"

2024-03-04 Thread Bill Dunlap
ame("<<-") > leftArrow <- as.name("<-") > ast1 <- parse(text=encode("x1 + x2 -> a3"))[[1]] > ast2 <- parse(text=encode("y4 <- b5 + (b6 / b7)"))[[1]] > identical(ast1[[1]], rightArrow) [1] TRUE > identical(ast2[[1]], leftA

Re: [Rd] specials and ::

2024-08-26 Thread Bill Dunlap
){ expr[[i]] <- fix(expr[[i]]) } } expr } fix(formula) } identical(f(y ~ f(x) + survival::g(x,10) + z), y ~ f(x) + g(x,10) + z) # [1] TRUE -Bill On Mon, Aug 26, 2024 at 7:42 AM Therneau, Terry M., Ph.D. via R-devel < r-devel@r-project.org>

Re: [Rd] specials and ::

2024-08-27 Thread Bill Dunlap
identical(expr[[2]], survival)) to specialNames <- c("strata", "whatever") ... if (is.call(expr) && identical(expr[[1]], doubleColon) && identical(expr[[2]], survival) && is.name(expr[[3]]) && is.element(as.character(expr[[3]]), specialNames

[Rd] How to convert time_t to R date object

2014-03-16 Thread Bill Wang
Hi all, I am writing a R extensions, and I need pass time_t to R in C, but I don't know how to do. Can you give me some help? do not use double directly. Thanks, Bill -- *Travel | Programming* *http://freecnpro.net* <http://freecnpro.net> [[alternative HTML vers

Re: [Rd] How to convert time_t to R date object

2014-03-16 Thread Bill Wang
Hi Dirk, Thanks for your reply, I neede convert time_t to R type in C code, can not use Rcpp. Maybe Rcpp source code could help me. Cheers, Bill 2014-03-16 22:55 GMT+08:00 Dirk Eddelbuettel : > > On 16 March 2014 at 18:36, Bill Wang wrote: > | I am writing a R extensions, and I

Re: [Rd] How to convert time_t to R date object

2014-03-17 Thread Bill Wang
Hi Sandip, I think that you know on the 64-bit Unix/Linux/OS X platforms, long is 64-bit whereas int and INTEGER are 32-bit, so return directly Integer unexpected problems may occur. Cheers, Bill 2014-03-17 13:24 GMT+08:00 Sandip Nandi : > Hi Bill , > > The following C code may

[Rd] textConnection performance quadratic (PR#14053)

2009-11-09 Thread bill . hopkins
Full_Name: William E. Hopkins Version: 2.9.0 OS: Windows XP Submission from: (NULL) (209.244.4.106) textConnection() has quadratic performance. A function I wrote was taking outrageous amount of time to execute on a large character vector (small test set was used for functional development). I c

[Rd] Question on trying to build R 2.11.1 on Tru64(aka OSF1) system

2010-06-08 Thread Bill . Glessner
t (see R-admin) that our main intention is to allow a ## LAPACK-containing BLAS to be used, so this is rarely needed, and ## it is not used if the BLAS already contains LAPACK. ## LAPACK_LIBS= ## Make name. ## Set this if you want to use a make by another name. ## For example, if your GNU make is called 'gmake', use 'MAKE=gmake'. ## MAKE= MAKE=gnumake ## Tar name ## Set this to prefer a tar which has the capability to automagically ## read compressed archives. The default is to choose 'gtar' (normally ## GNU tar) then 'tar', but other possibilities include 'bsdtar' from ## the libarchive project. ## TAR= TAR=gnutar In looking through the R documentation I didn't see any reference to "@" as a function/variable/language element/etc. Thanks for your help, Bill __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel

Re: [Rd] Question on trying to build R 2.11.1 on Tru64(aka OSF1) system

2010-06-08 Thread Bill . Glessner
txt" ;; Rd2pdf) cmd="${R_HOME}/bin/Rd2dvi" extra="--pdf" ;; *) if test -x "${R_HOME}/bin/${1}"; then cmd="${R_HOME}/bin/${1}" else cmd="${1}" fi ;; esac shift exec "${cmd}" ${extra} "$

Re: [Rd] Question on trying to build R 2.11.1 on Tru64(aka OSF1)

2010-06-09 Thread Bill . Glessner
ot;${R_HOME}/etc${R_ARCH}/Renviron" export `sed 's/^ *#.*//; s/^\(.*\)=.*/\1/' "${R_HOME}/etc${R_ARCH}/Renviron"` extra= case "$...@}" in perl) cmd="${PERL}" ;; awk) cmd="${AWK}" ;; ## this was a separate command prior to 2.10.0 Rd

Re: [Rd] Question on trying to build R 2.11.1 on Tru64(aka OSF1)

2010-06-10 Thread Bill . Glessner
2.11.1_build/bin/Rcmd: @: not found gnumake[2]: *** [MASS.ts] Error 1 gnumake[2]: Leaving directory `/usrX/JunqueYard/R-2.11.1_build/src/library/Recom mended' gnumake[1]: *** [recommended-packages] Error 2 gnumake[1]: Leaving directory `/usrX/JunqueYard/R-2.11.1_build/src/library/Recom mended'

Re: [Rd] proposal to allow just transcript files (output only) in the 'tests' directory

2007-02-20 Thread Bill Dunlap
Splus: Splus: Coefficients: Splus: (Intercept) x Splus:0.2432038 0.2304068 Splus: Splus: Degrees of freedom: 10 total; 8 residual Splus: Residual standard error: 0.2388027 This would also be handy for comparing results in different versions of R, where low lev

Re: [Rd] save() and interrupts

2007-04-16 Thread Bill Dunlap
an interrupt you remove the temp file, and on 'kill -9' the only bad effect is the space used by the partially written temp file.) This has the added advantage that you don't overwrite an existing save file by the given name until you know a suitable replacement is ready. Perhaps

Re: [Rd] plot.xy() with type="s" and huge data (PR#9629)

2007-04-23 Thread Bill Dunlap
someone changed the stack pointer.) type='S' also uses alloca(). ---- Bill Dunlap Insightful Corporation bill at insightful dot com 360-428-8146 "All statements in this message represent the opinions of the author and do not necessarily reflect Insightful Corporation

Re: [Rd] R CMD Rdconv drops sections: arguments, seealso, examples (PR#9606)

2007-04-30 Thread Bill Dunlap
On Tue, 10 Apr 2007 [EMAIL PROTECTED] wrote: > I've created a .Rd file (below), then converted that to .sgml using > R CMD Rdconv --type=Ssgm combn.Rd > combn.sgml > The output (shown below) is missing some of the sections: > arguments > seealso > examples > If instead I c

Re: [Rd] R CMD Rdconv drops sections: arguments, seealso, examples (PR#9645)

2007-05-01 Thread Bill Dunlap
On Mon, 30 Apr 2007 [EMAIL PROTECTED] wrote: > On Tue, 10 Apr 2007 [EMAIL PROTECTED] wrote: > > > I've created a .Rd file (below), then converted that to .sgml using > > R CMD Rdconv --type=Ssgm combn.Rd > combn.sgml > > The output (shown below) is missing some of the sections: > > argume

Re: [Rd] R CMD Rdconv drops sections: arguments, seealso, examples (PR#9649)

2007-05-07 Thread Bill Dunlap
t;. + " on or after line $badlineno\n"; } + } } - if( $extra_info =~ /^'}'$/ ) { - warn "Note: unmatched right brace in '$Rdname'". - " on or after line $badlineno\n"; -

Re: [Rd] optim bug (PR#9684)

2007-05-15 Thread Bill Dunlap
14 May 2007, [EMAIL PROTECTED] wrote: > > 'optim' does not accept arguments called 'u'. Here is an example: > > > R> fun<-function(x,u) (x-u)^2 > > R> optim(7,fn=fun,u=9) > > > > Fehler in fn(par, ...) : Argument "u" fehlt

Re: [Rd] RFC: adding an 'exact' argument to [[

2007-05-17 Thread Bill Dunlap
operator alone, so it will continue to do partial matching? I suspect that that is where the majority of partial matching for list names is done. It might be nice to have an option that made x$partial warn so we would fix code that relied on partial matching, but that is lower priority.

Re: [Rd] Possible changes to connections

2007-05-31 Thread Bill Dunlap
etpid(),"|grep /tmp/twolines.txt")) > readLines(file("/tmp/twolines.txt", open="rb")) [1] "One," "two, and that is it." > system(paste("/usr/sbin/lsof -p", Sys.getpid(),"|grep /tmp/twolines

Re: [Rd] C function with unknown output length

2007-06-06 Thread Bill Dunlap
(retval)) Rprintf("expanding retval from %d to %d moved it\n", retval_length-1, retval_length) ; NUMERIC_POINTER(retval)[retval_length-1] = r ; } PutRNGstate(); return retval ; } -------- Bil

Re: [Rd] package check note: no visible global function definition (in functions using Tcl/Tk)

2007-06-14 Thread Bill Dunlap
lly works when pkgName is not available. This might overload the nightly build machine, but would be useful for the developer. Bill Dunlap Insightful Corporation bill at insightful dot com 360-428-8146 "All statem

Re: [Rd] data messed up by read.table ? (PR#9779)

2007-07-05 Thread Bill Dunlap
rub 4.7T4 > 22Pound.Hill 4.4 2 Arable 4.5F5 > 23 Gravel.Pit 2.9 1 Grassland 3.5F1 > 24 Farm.Wood 0.810 Scrub 5.1T3 -

Re: [Rd] (PR#9796) write.dcf/read.dcf cycle converts missing entry

2007-07-18 Thread Bill Dunlap
s read: Version, NoSuchField and now it doesn't print anything about the non-existant field > packageDescription("base", fields=c("Version","NoSuchField")) Version: 2.6.0 -- File: /homes/bill/R-svn/r-devel/R/library/base/DESCRIPTION -- Fields read: Ver

Re: [Rd] dict package: dictionary data structure for R

2007-07-22 Thread Bill Dunlap
45 6514 1486 2717 1608 289 20 Perhaps new.env() should push the requested size up to the next prime by default. (This is not to say your other changes are not improvements.) Bill Dunlap Insightful Corporation bill at insightful dot com 360-428-8146 "All statements in this message repr

Re: [Rd] Rd2dvi (PR#9812)

2007-07-26 Thread Bill Dunlap
ave added > # a close rdfile at the end of the while(), but > # scoping method is more reliable. 123c127 < while(){ --- > while(<$rdfile>){ Bill Dunlap Insightful Corporation bill at insigh

Re: [Rd] sequence(c(2, 0, 3)) produces surprising results, would like output length to be sum(input) (PR#9811)

2007-07-26 Thread Bill Dunlap
On Thu, 26 Jul 2007 [EMAIL PROTECTED] wrote: > Full_Name: Bill Dunlap > Version: 2.5.0 > OS: Linux > Submission from: (NULL) (70.98.76.47) > > sequence(nvec) is documented to return > the concatenation of seq(nvec[i]), for > i in seq(along=nvec). This produces inconvenien

Re: [Rd] Use of all/any

2007-10-26 Thread Bill Dunlap
On Fri, 26 Oct 2007, Bill Dunlap wrote: > In Splus I use >rapply(expr, classes="call", > f=function(x)if(isComparisonOfAnyOrAll(x))deparseText(x)) > to rattle down an an expression tree looking for this pattern. > However's R's rapply won't let m

Re: [Rd] Use of all/any

2007-10-26 Thread Bill Dunlap
On Fri, 26 Oct 2007, Martin Maechler wrote: > Apropos Bill Dunlap's note: Do newer versions of S-plus warn? > At least up to 6.2.2, I'm pretty sure no S version has warned > about > X <- c(0.1, pi) > all(X) > 0.5 Hi Martin, No, it doesn't warn.

Re: [Rd] C/C++ 'assert' should not be used in R packages

2007-11-10 Thread Bill Dunlap
ge? I think I could do something like that > in Windows by calling FreeLibrary to unload the DLL, but I'd prefer a > cross-platform solution. Bill Dunlap Insightful Corporation bill at insightful dot com 360-4

Re: [Rd] read.table: aborting based on a time constraint

2008-01-09 Thread Bill Dunlap
it to catch the interrupt. This is pretty ugly, but I was wondering if R had the facilities to write such a timeout() function. I used to use it to automate tests of infinite-loop bugs. Bill Dunlap Insightful Corporation bill at insightful dot com 360-428-8146 "All statements in this

  1   2   >