Displaying 20 results from an estimated 1000 matches similar to: "cummax / cummin for complex numbers"
2015 May 17
1
The function cummax() seems to have a bug.
Hi,
The function cummax() seems to have a bug.
> x <- c(NA, 0)
> storage.mode(x) <- "integer"
> cummax(x)
[1] NA 0
The correct result of this case should be NA NA. The mistake in [
https://github.com/wch/r-source/blob/trunk/src/main/cum.c#L130-L136] may be
the reason.
Best Regards,
Dongcan
--
Dongcan Jiang
Team of Search Engine & Web Mining
School of Electronic
2011 Oct 04
1
a question about sort and BH
Hi,
I have two questions want to ask.
1. If I have a matrix like this, and I want to figure out the rows whose
value in the 3rd column are less than 0.05. How can I do it with R.
hsa-let-7a--MBTD1 0.528239197 2.41E-05
hsa-let-7a--APOBEC1 0.507869409 5.51E-05
hsa-let-7a--PAPOLA 0.470451884 0.000221774
hsa-let-7a--NF2 0.469280186 0.000231065
hsa-let-7a--SLC17A5
2014 Feb 12
1
FastR
Dear all,
at UseR! 2013, the FastR project was announced by Tomas Kalibera, Petr Maj, and Jan Vitek. FastR is an implementation of the R programming language in Java using AST interpretation and specialisation for improved performance. Since, the implementation has been extended to support JIT compilation, leading to performance improvements.
The goal of the project is to further the R community
2014 Sep 04
2
negative numerics in []
Hello,
I'm a bit puzzled by what looks (to me) like a discrepancy between documentation and implementation.
The documentation for [] says this about the indices: "Numeric values are coerced to integer as by as.integer (and hence truncated towards zero)."
> as.integer(-3.1)
[1] -3
Good. But:
> x <- c(1,2,3)
> x[-3.1]
[1] 1 2 3
Given the documentation, I'd have
2017 Jan 20
1
NaN behavior of cumsum
Hi!
I noticed that cumsum behaves different than the other cumulative functions wrt. NaN values:
> values <- c(1,2,NaN,1)
> for ( f in c(cumsum, cumprod, cummin, cummax)) print(f(values))
[1] 1 3 NA NA
[1] 1 2 NaN NaN
[1] 1 1 NaN NaN
[1] 1 2 NaN NaN
The reason is that cumsum (in cum.c:33) contains an explicit check for ISNAN.
Is that intentional?
IMHO, ISNA would be better
2005 May 13
1
Lowest data level since DateX
Hello,
I'm dealing with financial time series. I'm trying to find out X in this
sentence:
The most recent close is the lowest level since X(date).
Here's an example of what I'm looking for:
library(fBasics)
data(DowJones30)
tail(DowJones30[,1:5],n=10)
I need to come up with a vector that would look like this
AA AXP T ...
2000-12-21
2010 May 05
1
testInstalledBasic question
Hi,
I'm currently in the process of writing an R-installation SOP for my
company. As part of that process I'm using the recommendations from the 'R
Installation and Administration' document, section 3.2, "Testing an
installation". This is done on an XP machine, using the latest binary of
2.11.0.
The binary is downloaded and then installed from the installer. I then
2014 Aug 14
1
`*tmp*`
Hello,
given that `*tmp*` is removed after a replacement, how can code like this work? Is there some special handling for a variable named `*tmp*` when it comes to make element assignments?
> x<-c(1,2)
> x[1]<-42
> `*tmp*`[1]<-7 # I would expect this one to fail
> `*tmp*`
Error: object '*tmp*' not found
Confused greetings,
Michael
--
Dr. Michael Haupt
Principal
2014 Jan 23
0
internship at Oracle Labs
Dear all,
we are offering an internship position at Oracle Labs, in Redwood Shores (CA) or Potsdam (Germany). An outline of the job description can be found below. Additional details can be found at https://irecruitment.oracle.com (search for IRC2419637).
Best regards,
Michael Haupt
"In the context of the Alphabet Soup project, Oracle Labs is contributing to an open-source optimised
2007 Feb 01
2
file_column 2nd try....
Looks like my first question a couple of days ago wasn?t very clever
asked, at least very sucessfull....
So, anyway...i will try it again:
I have to prefix that I am far away from fully understanding the overall
concept yet, and there?s no way to get some hints in the www so far, at
least my resaerches dont lead to any helpfull stuff.
image_controller.rb:
def create
MiddleMan.new_worker
2006 Jun 13
17
reconstituting a date
In my view code, I have <%= datetime_select "in_out", "time_in" %>
which returns in params
:in_out: !map:HashWithIndifferentAccess
time_in(1i): "2006"
time_in(2i): "6"
time_in(3i): "12"
time_in(4i): "20"
time_in(5i): "24"
and I want to save that datetime to a column in the db...
if
2011 May 19
1
update_attributes updates data from second instance of nested form but not the first
Got a weird situation with an update put to a controller with a form with
nested attributes.
On the data below, I am updating data for both items (''0'' and ''1'') in
rosters_attributes (in the example below I am updating the ''name'' attribute
to a new value in both cases. What I am stuck on is that ''1'' gets its data
updated,
2006 Aug 10
1
Convert datetime_select to Time object?
--------------------------
Question 1
--------------------------
I am dealing with a database that holds products and it has a datetime
field called "active_at". so I have the following for active_at:
<%= f.datetime_select :active_at %>
It gives me 5 different params:
params[:product][:active_at(1i)]
params[:product][:active_at(2i)]
params[:product][:active_at(3i)]
2006 Jul 18
1
Auto-populating time portion of a datetime field from a form
I see that if I use the date_select helper in my view, then in the
generated page, my selects are named obj[datetime_field(1i)] (and 2i and
3i for the other parts). These auto-populate the date portion of my
datetime_field.
I have another datetime field that I''m presenting the time from and I
would like to use a similar scheme to autopopulate it. Currently, I''ve
used the
2006 Apr 18
1
inserting value got problem
Parameters: {"bestandsliste"=>{"typ"=>"bumffer", "KundanName"=>"parikshit", "Abgeholt"=>"", "LieferLand"=>"", "Kaufmann"=>"birla", "Marge"=>"", "Erzieltervk"=>"", "LieferOrt"=>"",
2005 Jan 16
1
p.adjust(<NA>s), was "Re: [BioC] limma and p-values"
I append below a suggested update for p.adjust().
1. A new method "yh" for control of FDR is included which is valid for any
dependency structure. Reference is Benjamini, Y., and Yekutieli, D. (2001).
The control of the false discovery rate in multiple testing under
dependency. Annals of Statistics 29, 1165-1188.
2. I've re-named the "fdr" method to "bh" but
2006 Jul 06
3
Understanding date_select naming conventions
I am using the date_select helper to generate date select elements in a
form.
I notice that the generated HTML shows that these selects have the
following names:
Month: current_job[StartDate(2i)]
Day: current_job[StartDate(3i)]
Year: current_job[StartDate(1i)]
I''m assuming that the Xi identifiers somehow specify the appropriate
date part from a date or time value.
Can anyone
2011 Dec 12
2
Problema para cargar "lme4" en R version 2.14.0
Hola,
Tenía una versión anterior de R, la 2.10.1 en la cual podía cargar perfectamente el paquete "lme4". Actualicé la versión del R a 2.14.0 y aún volviendo a descargar la nueva versión del paquete mencionado cuando intento cargarlo me da el siguiente error :
> library(lme4)
Error: package ‘lme4’ is not installed for ''arch=i386''
Hay alguna solución para esto o
2008 Jan 07
3
Seeking a more efficient way to find partition maxima
Hi.
Suppose I have a vector that I partition into disjoint, contiguous subvectors. For example, let v = c(1,4,2,6,7,5), partition it into three subvectors, v1 = v[1:3], v2 = v[4], v3 = v[5:6]. I want to find the maximum element of each subvector. In this example, max(v1) is 4, max(v2) is 6, max(v3) is 7. If I knew that the successive subvector maxima would never decrease, as in the example,
1998 May 06
1
min(numeric(0)) = ? -- proposal for "S incompatible change"
[Same question for max(.), cummin(.) and cummax(.)]
In S, S-plus and R, this currently gives NA.
I wonder if it wouldn't make more sense to follow common
mathematical/logical reasoning here:
min { empty set } = +Inf
max { empty set } = -Inf
(For integers, these would be INT_MAX and INT_MIN, respectively).
Maybe this is a real ``first time'':
I am proposing a change which