Re:Parsing R code: Freedom of expression is not always a goo...
by jghn on Tuesday June 14, 2022 @10:47AM
(#31740309)
Yeah. There's a difference between "This language isn't being internally consistent" and "Due to my experience using language X, I find this confusing". As you say, this is well documented behavior, albeit perhaps unexpected to a novice R user.
https://www.rdocumentation.org/packages/raster/versions/3.5-...
> Change values of a Raster* object to logical or integer values. With as.logical, zero becomes FALSE, all other values become TRUE. With as.integer values are truncated.