similar to: Question R's parser : - parsing "x=\n 1"

Displaying 20 results from an estimated 300 matches similar to: "Question R's parser : - parsing "x=\n 1""

2019 Aug 30
1
?Syntax wrong about `?`'s precedence ?
...and 14955, which seems to have the explanation (but was marked as closed/fixed??). The parser does list '?' as lower precedence than '=', but '='-assignments are not normal 'expr's which can appear as arguments to '?'. (Presumably because of named arguments: f(a=b) differs from f(a<-b).) Other tokens which have lower precedence than assignments are
2016 Oct 21
3
anonymous function parsing bug?
Hi, I hope this is the correct list for my question. I found a wired behaviour of my R installation on the evaluation of anonymous functions. minimal working example ### f<-function(x) { print( 2*x ) }(2) class(f) f(3) f<-function(x) { print( 2*x ) }(4)(5) f(6) ### leads to ### > f<-function(x) { + print( 2*x ) + }(2) > > class(f) [1] "function"
2007 Oct 01
1
tricky problem with "if" function -
Hi all, This question involves using a "for" loop to make a "decision" in a script. I've written a rather intricate script, and near the start of it, I want it either to do a loop (if a variable called "number.runs" > 1) or not do a loop (if "number.runs" is 1). This is probably trivial but I can't figure it out. Here's a self-contained
2019 Jul 05
0
parse() drops parse data when encountering `` (bug?)
Hi, I've noticed that partial parse data from parse() is irretrivable when it errors due to encountering '``' - two backticks in sequence. The print output also looks more limited than a regular parser error which leads me to suspect this is a bug. If this is the case could someone with the authority please add it to R's bug tracker? My reprex follows. Thanks, Miles ``` r
2016 Oct 21
3
anonymous function parsing bug?
Hi, thx for the reply. Unfortunately that is not a simplified version of the problem. You have a function, call it and get the result (numeric in, numeric out in that case). For simplicity lets use the "return" case: ## foobar<-function(x) { return(sqrt(x)) }(2) ## which is a function (numeric in, numeric out) which is defined, then gets called and the return value is a function
2019 Aug 30
3
?Syntax wrong about `?`'s precedence ?
Precedence is a property of the parser and has nothing to do with the semantics assigned to various symbols. Using just core R functions you can see the precedence of '?' is between those of '=' and '<-'. > # '=' has lower precedence than '?' > str(as.list(parse(text="a ? b = c")[[1]])) List of 3 $ : symbol = $ : language `?`(a, b) $
2008 Jan 11
0
nlme model specification (revisit)
Hi List, While using 'nlme' function, I have encountered the similar problem Dr. Stevens and Dr. Graves observed (please see the posts: https://stat.ethz.ch/pipermail/r-help/2006-May/105832.html ). I have tried Dr. Stevens's original example, the problem is still there, > mod.lis <- nlsList(circumference ~ SSlogis(age, Asymp, xmid, scal), + data=Orange ) >
2016 Oct 21
0
anonymous function parsing bug?
Here is a simplified version of your problem > { sqrt }(c(2,4,8)) [1] 1.414214 2.000000 2.828427 Do you want that to act differently? Bill Dunlap TIBCO Software wdunlap tibco.com On Fri, Oct 21, 2016 at 6:10 AM, Wilm Schumacher <wilm.schumacher at gmail.com> wrote: > Hi, > > I hope this is the correct list for my question. I found a wired behaviour > of my R
2016 Oct 21
0
anonymous function parsing bug?
Are you saying that f1 <- function(x) log(x) f2 <- function(x) { log } (x) should act differently? Using 'return' complicates the matter, because it affects evaluation, not parsing. Bill Dunlap TIBCO Software wdunlap tibco.com On Fri, Oct 21, 2016 at 8:43 AM, Wilm Schumacher <wilm.schumacher at gmail.com> wrote: > Hi, > > thx for the reply. Unfortunately
2010 Oct 17
0
make error for R 2.13.0
Hi dear all It's the first time for me to install a developmental version of R, I came across following errors, my system is DISTRIB_ID=Ubuntu DISTRIB_RELEASE=10.04 DISTRIB_CODENAME=lucid DISTRIB_DESCRIPTION="Ubuntu 10.04.1 LTS" I downloaded the dev version of R in cran R source, and downloaded the recommended packages by using wget as described in R manual, and run
2014 May 22
1
citEntry handling of encoded URLs
The following citEntry includes a url with %3A and other encodings citEntry(entry="article", title = "Software for Computing and Annotating Genomic Ranges", author = personList( as.person("Michael Lawrence" )), year = 2013, journal = "{PLoS} Computational Biology", volume = "9", issue =
2017 Mar 16
4
Support for user defined unary functions
R has long supported user defined binary (infix) functions, defined with `%fun%`. A one line change [1] to R's grammar allows users to define unary (prefix) functions in the same manner. `%chr%` <- function(x) as.character(x) `%identical%` <- function(x, y) identical(x, y) %chr% 100 #> [1] "100" %chr% 100 %identical% "100" #> [1] TRUE
2019 Aug 16
0
Wine release 4.14
The Wine development release 4.14 is now available. What's new in this release (see below for details): - New version of the Mono engine with upstream updates. - PE dlls no longer rely on the MinGW runtime. - Exception handling fixes on ARM64. - Various bug fixes. The source is available from the following locations: https://dl.winehq.org/wine/source/4.x/wine-4.14.tar.xz
2018 Jul 30
2
Problem with parseData
Hi, I have run into a problem with parseData from the utils package.? When an assignment is done with = instead of <-, the information provided by parseData does not include an entry for the assignment. For this input, stored in file "BadPosition.R": y <- 5 foo = 7 And running this code: parsed <- parse("BadPosition.R", keep.source=TRUE) parsedData <-
2003 Aug 24
1
declarations in non-exported headers and embedding R
Hello, I've been using R embedded in PL/R (R procedural language handler for PostgreSQL, http://www.joeconway.com/plr/) very successfully for several months now. A sincere "thank you" goes to the R development team for such a great product. I have a question I'm hoping someone here can help me with. In order to get the required functionality out of PL/R, I've had to
2006 Jun 29
3
Continuation and parse
Hi gurus, After an unsuccessful scrabble through the documentation and Jon's excellent search facility, I am no wiser as to how R recognizes an incomplete command line and politely raises its hand for more. The help page for parse gives no indication that it does anything more than spit the dummy when fed an incomplete command line, but something in there must recognize such ellipsis.
2006 Jun 29
3
Continuation and parse
Hi gurus, After an unsuccessful scrabble through the documentation and Jon's excellent search facility, I am no wiser as to how R recognizes an incomplete command line and politely raises its hand for more. The help page for parse gives no indication that it does anything more than spit the dummy when fed an incomplete command line, but something in there must recognize such ellipsis.
2018 Oct 02
1
Problem with parseData
The fix is now in R-devel, 75386. I have not ported to R-patched, because the fix breaks two packages which are working around this bug (and to my knowledge without having reported it before). So thanks again for the report! Best Tomas On 08/16/2018 10:06 AM, Tomas Kalibera wrote: > Dear Barbara, > > thank you for the report. This is something to be fixed in R - I am > now
2017 Mar 16
2
Support for user defined unary functions
Gabe, The unary functions have the same precedence as normal SPECIALS (although the new unary forms take precedence over binary SPECIALS). So they are lower precedence than unary + and -. Yes, both of your examples are valid with this patch, here are the results and quoted forms to see the precedence. `%chr%` <- function(x) as.character(x) `%identical%` <- function(x, y)
2010 Jan 07
1
Segfault in GetNewPage, memory.c.
Hello. I'm still working on my OCaml-R binding and I get a segfault in the GetNewPage() function of memory.c. For the record, the OCaml-R binding seems to work fine with OCaml bytecode. The segfault here is the main issue I have with OCaml native code. OCaml-R can be found on the following links. Source code: http://yziquel.homelinux.org/gitweb/?p=ocaml-r.git;a=summary