Displaying 10 results from an estimated 10 matches for "reclassing".
Did you mean:
reclaiming
2009 Dec 04
2
Class attributes
...ain "x" are
still considered factors and I am unable to coerce them into numeric:
> mean.species.biomass<-colMeans(as.numeric(dd.p[,5:12]))
>Error in inherits(x, "data.frame") :
(list) object cannot be coerced to type 'double'
I'm tried unclassing & reclassing, other functions etc. but nothing seems to
work. What is wrong?
Thanks in advance,
Allen
--
View this message in context: http://n4.nabble.com/Class-attributes-tp948693p948693.html
Sent from the R help mailing list archive at Nabble.com.
2023 Apr 28
2
range() for Date and POSIXct could respect `finite = TRUE`
Hi all,
I noticed that `range.default()` has a nice `finite = TRUE` argument,
but it doesn't actually apply to Date or POSIXct due to how
`is.numeric()` works.
```
x <- .Date(c(0, Inf, 1, 2, Inf))
x
#> [1] "1970-01-01" "Inf" "1970-01-02" "1970-01-03" "Inf"
# Darn!
range(x, finite = TRUE)
#> [1] "1970-01-01"
2004 Mar 15
2
R equiv to proc gremove in maps package
Is there an R equivalent to SAS's proc gremove? You would use this procedure to combine the units on an existing map, for example to build a map of Metropolitan Statistical Areas (MSAs) from the [US] counties dataset where the internal boundries surround the MSAs (which are groups of counties) rather than the individual counties. I can imagine the mechanism would be to find and erase the
2023 Apr 28
1
range() for Date and POSIXct could respect `finite = TRUE`
A tiny nit-pick: Seems to me that end date = NA would mean the event has
not yet ended, whilst Inf would mean that the event is known to never
terminate, ie: an eternal fact, or physical law.
On Fri, Apr 28, 2023 at 10:12?AM Davis Vaughan via R-devel <
r-devel at r-project.org> wrote:
> Hi all,
>
> I noticed that `range.default()` has a nice `finite = TRUE` argument,
> but it
2019 Mar 26
0
Discrepancy between is.list() and is(x, "list")
Hi Abs,
Lets try to remain civil even when disagreeing about major design
philosophies, ok?
On Tue, Mar 26, 2019 at 2:08 PM Abs Spurdle <spurdle.a at gmail.com> wrote:
> If I can merge this thread with the one I started yesterday...
>
> > "If the object does not have a class attribute, it has an implicit
> class..."
> > which I take to mean that if an object
2023 May 19
1
range() for Date and POSIXct could respect `finite = TRUE`
Hi All,
I think there may be some possible confusion about what allowsInf would be
reporting (or maybe its just me :) ) if we did this.
Consider a class "myclass", S3, for starters,
with
setMethod("allowsInf", "myclass", function(obj) FALSE)
Then, what would
myclassthing <- structure(1.5, class = "mything")
myclassthing[1] <- Inf
do. Assumely it
2019 Mar 26
4
Discrepancy between is.list() and is(x, "list")
If I can merge this thread with the one I started yesterday...
> "If the object does not have a class attribute, it has an implicit
class..."
> which I take to mean that if an object does have a class attribute it
does not also have an implicit class.
> I think this is reasonable behavior. Consider the "Date" class, which
stores values as "numeric":
>
2009 Mar 10
4
puzzled by math on date-time objects
Hi,
I don't understand the following. When I create a small artificial set
of date information in class POSIXct, I can calculate the mean and the
median:
a = as.POSIXct(Sys.time())
a = a + 60*0:10; a
[1] "2009-03-10 11:30:16 EDT" "2009-03-10 11:31:16 EDT" "2009-03-10
11:32:16 EDT"
[4] "2009-03-10 11:33:16 EDT" "2009-03-10 11:34:16
2011 Feb 08
4
manipulating the Date & Time classes
Hello,
This is mostly to developers, but in case I missed something in my
literature search, I am sending this to the broader audience.
- Are there any plans in the works to make "time" classes a bit more
friendly to the rest of the "R" world? I am not suggesting to allow for
fancy functions to manipulate times, per se, or to figure out how to
properly
2011 Feb 08
4
manipulating the Date & Time classes
Hello,
This is mostly to developers, but in case I missed something in my
literature search, I am sending this to the broader audience.
- Are there any plans in the works to make "time" classes a bit more
friendly to the rest of the "R" world? I am not suggesting to allow for
fancy functions to manipulate times, per se, or to figure out how to
properly