search for: wdunlap

Displaying 20 results from an estimated 1260 matches for "wdunlap".

Did you mean: dunlap
2016 Oct 04
2
error handling in strcapture
...= "factor"), Number = c(1, NA, 50)), row.names = c(NA, -3L), class = "data.frame") all.equal(e9p, r9p) } #Error in if (any(ind)) { : missing value where TRUE/FALSE needed Bill Dunlap TIBCO Software wdunlap tibco.com On Wed, Sep 21, 2016 at 2:32 PM, Michael Lawrence <lawrence.michael at gene.com > wrote: > The new behavior is that it yields NAs when the pattern does not match > (like strptime) and for empty captures in a matching pattern it yields > the empty string, which is consiste...
2016 Oct 04
1
error handling in strcapture
...n matrix(as.character(unlist(str)), ncol = ntokens, byrow = TRUE) : data length [20] is not a sub-multiple or multiple of the number of rows [7] > strcapture("(.)(.)(.)", c("abc", "def"), proto=list(A="")) A 1 a 2 c 3 d 4 f Bill Dunlap TIBCO Software wdunlap tibco.com On Tue, Oct 4, 2016 at 2:21 PM, Michael Lawrence <lawrence.michael at gene.com> wrote: > Hi Bill, > > This is a bug in regexec() and I will commit a fix. > > Thanks for the report, > Michael > > On Tue, Oct 4, 2016 at 1:40 PM, William Dunlap <wdunlap at...
2017 Oct 09
1
Regular expression help
"(^| +)([^/ ]*/?){0,2}", with the first "*" replaced by "+" would be a bit better. Bill Dunlap TIBCO Software wdunlap tibco.com On Mon, Oct 9, 2017 at 8:50 AM, William Dunlap <wdunlap at tibco.com> wrote: > > x <- "f 147/1315/587 2820/1320/587 3624/1321/587 1852/1322/587" > > gsub("(^| *)([^/ ]*/?){0,2}", "\\1", x) > [1] " 587 587 587 587" > >...
2015 Jul 15
2
bquote/evalq behavior changed in R-3.2.1
...ained in the question that the above code does not work. It does not throw an error, but the behavior is no different (at least in the output or result). Using the above code still results in the x object not being stored in fenv on 3.1.2. Dayne On Wed, Jul 15, 2015 at 4:40 PM, William Dunlap <wdunlap at tibco.com> wrote: > Another aspect of the change is (using TERR's RinR package): > > options(REvaluators=list(makeREvaluator("R-3.1.3"), > makeREvaluator("R-3.2.0"))) > > RCompare(rapply(list(quote(function(...
2016 Sep 09
3
Different results for tan(pi/2) and tanpi(1/2)
The same argument would hold for tan(pi/2). I don't say the result 'NaN' is wrong, but I thought, tan(pi*x) and tanpi(x) should give the same result. Hans Werner On Fri, Sep 9, 2016 at 8:44 PM, William Dunlap <wdunlap at tibco.com> wrote: > It should be the case that tan(pi*x) != tanpi(x) in many cases - that is why > it was added. The limits from below and below of the real function > tan(pi*x) as x approaches 1/2 are different, +Inf and -Inf, so the limit is > not well defined. Hence the comp...
2017 Dec 29
1
winbuilder warning message wrt function pointers
...ble("bdsmatrix", "bdsmatrix_prod4"); } if (fun==NULL) { Rf_error("Cannot find C function 'bdsmatrix_prod4' in library 'bdsmatrix.{so,dll}'"); } fun(nrow, nblock, bsize, bmat, rmat, nfrail, y); } Bill Dunlap TIBCO Software wdunlap tibco.com On Fri, Dec 29, 2017 at 8:48 AM, William Dunlap <wdunlap at tibco.com> wrote: > Try changing > static void (*fun)() = NULL; > to > DL_FUNC fun = NULL; > > Bill Dunlap > TIBCO Software > wdunlap tibco.com > > On Fri, Dec 29, 2017 at 5:14 AM, Therne...
2015 Mar 30
3
Segfault with match()
This is admittedly a contrived example, but... data(housing, package ="MASS") x <- housing$Type + housing$Sat match(x, unique(x)) Hadley -- http://had.co.nz/
2017 Dec 29
3
winbuilder warning message wrt function pointers
I've recently updated the coxme package, which calls internal routines from the bdsmatrix package.? (It is in fact mentioned as an example of this in the Extensions manual.) The call connections are a blocks like this, one for each of the 9 called C routines. void bdsmatrix_prod4(int nrow,??? int nblock,?? int *bsize, ??????????????????? double *bmat, double *rmat, ??????????????????? int
2019 Sep 08
1
Error: package or namespace load failed for ‘utils
Also, check the settings of R_HOME and/or R_LIBS. Bill Dunlap TIBCO Software wdunlap tibco.com On Sun, Sep 8, 2019 at 9:58 AM William Dunlap <wdunlap at tibco.com> wrote: > Look at section 6.1 of the R Installation and Admin manual. > > 6.1 Default packages > > The set of packages loaded on startup is by default > > > getOption("defaultPackages...
2016 Sep 21
2
error handling in strcapture
...if the prototype is compatible with the pattern, so should strcapture just assume the best and fill in the prototype with NA's? Should there be warnings? This is kind of like strptime(), which silently gives NA's when the format does not match the text input. Bill Dunlap TIBCO Software wdunlap tibco.com On Wed, Sep 21, 2016 at 2:10 PM, Michael Lawrence <lawrence.michael at gene.com > wrote: > Hi Bill, > > Thanks, another good suggestion. strcapture() now returns NAs for > non-matches. It's nice to have someone kicking the tires on that > function. > > Mic...
2012 Feb 07
2
Canonical package directory name for JAR files?
We have an R package which needs to include a JAR file. Is there a canonical directory for it?
2015 Jul 15
2
bquote/evalq behavior changed in R-3.2.1
...envir, enclos) : object 'X' not found > lapply(list(quote(1+myNumber)), eval, envir=list2env(list(myNumber=17))) > #[[1]] > #[1] 18 > > Make the FUN argument function(arg)sys.call() to see some details of the > change. > > > Bill Dunlap > TIBCO Software > wdunlap tibco.com > > On Wed, Jul 15, 2015 at 12:35 PM, Dayne Filer <dayne.filer at gmail.com> wrote: > >> In 3.1.2 eval does not store the result of the bquote-generated call in >> the given environment. Interestingly, in 3.2.1 eval does store the result >> of the bquote...
2012 Feb 07
5
Table rearranging
I have a table that looks like this: measurement?? ?date??? door ?? color 0.93529385?? ?513?? ?open?? ?red 0.97419293?? ?420??? open ?? red 0.962053514?? ?513?? ?closed?? ?red 0.963909937?? ?1230?? ?open?? ?blue 0.97652034?? ?1230?? ?open?? ?green 0.989310795?? ?1230?? ?closed?? ?blue 0.9941022?? ?917?? ?closed?? ?yellow I would like to create a table that has: Open measurement, Closed
2016 Apr 21
1
"cophenetic" function for objects of class "dendrogram"
Note that cophenetic.default (which works on the output of hclust(dist(X))) uses the row names of X as labels. as.dendrogram.hclust does not retain those row names so cophenetic.dendrogram cannot use them (so it orders them based on the topology of the dendrogram). Bill Dunlap TIBCO Software wdunlap tibco.com On Thu, Apr 21, 2016 at 7:59 AM, William Dunlap <wdunlap at tibco.com> wrote: > I think the results differ only in the order of the labels. The following > function > puts the labels in a standard order and then the results are the same: > > canonicalize.dist &lt...
2015 Nov 06
2
corrupt PACKAGES.gz?
...returned an internal error > tail(system(paste("c:\\cygwin\\bin\\gzip -d - ", shQuote(tfile)), intern=TRUE)) [1] "" "gzip: stdin: unexpected end of file" Warning message: running command 'c:\cygwin\bin\gzip -d - "C:\Users\wdunlap\AppData\Local\Temp\RtmpG42jk4\file2a201a9e4802.gz"' had status 1 R's gz code seems to recover from the bad seek, but Cygwin's gzip cannot. > pkgs <- paste(sep="/", repos, "bin/windows/contrib", v, "PACKAGES") > r <- readLines(url(pkgs, &q...
2015 Oct 07
3
read.table reads "i" as NA_complex_
...acter so most people will not notice > str(read.table(text=c("i\nii\niii\niv\n"))) 'data.frame': 4 obs. of 1 variable: $ V1: Factor w/ 4 levels "i","ii","iii",..: 1 2 3 4 Is this intended? It surprised me. Bill Dunlap TIBCO Software wdunlap tibco.com [[alternative HTML version deleted]]
2015 Jul 15
3
bquote/evalq behavior changed in R-3.2.1
...code on 3.2.1. However, the given example stores "x" in "fenv" on 3.1.2, but throws the error I gave when run on 3.2.1. To give credit, I received the idea for using evalq from SO: http://stackoverflow.com/a/22559385 Dayne On Wed, Jul 15, 2015 at 3:29 PM, William Dunlap <wdunlap at tibco.com> wrote: > I am curious why you used evalq instead of eval in this code. > > Bill Dunlap > TIBCO Software > wdunlap tibco.com > > On Wed, Jul 15, 2015 at 11:49 AM, Dayne Filer <dayne.filer at gmail.com> > wrote: > >> Hello, >> >> I...
2015 Apr 09
3
typo in R-exts.html section 6.9
...ne of the integration boundaries is not finite. An indefinite integral usually means an antiderivative, not an integral over an infinite spread. Should that first sentence end with 'for integrals over finite and infinite ranges' and the second sentence omitted? Bill Dunlap TIBCO Software wdunlap tibco.com [[alternative HTML version deleted]]
2016 Jul 27
2
Model object, when generated in a function, saves entire environment when saved
...formula (which is what drags along the environment it was created in), you will save space. E.g., tfun2 <- function(subset) { junk <- 1:1e6 list(subset=subset, lm(Sepal.Length ~ Sepal.Width, data=iris, subset=subset)$coef) } saveSize(tfun2(1:4)) #[1] 152 Bill Dunlap TIBCO Software wdunlap tibco.com On Wed, Jul 27, 2016 at 11:19 AM, William Dunlap <wdunlap at tibco.com> wrote: > One way around this problem is to make a new environment whose > parent environment is .GlobalEnv and which contains only what the > the call to lm() requires and to compute lm() in that envi...
2016 Oct 04
0
error handling in strcapture
Hi Bill, This is a bug in regexec() and I will commit a fix. Thanks for the report, Michael On Tue, Oct 4, 2016 at 1:40 PM, William Dunlap <wdunlap at tibco.com> wrote: > I noticed a problem in the strcapture from R-devel (2016-09-27 r71386), when > the text contains a missing value and perl=TRUE. > > { > # NA in text input should map to row of NA's in output, without > warning > r9p <- strcapture(per...