Hello list,
I am trying to specify the indices of an array with a list and add a
newaxis, but that combination doesn't seem to be allowed. Any reason why?
Here's an example:
a = arange(3)
This works:
a[[0,2]][:,newaxis]
Out[445]:
array([[0],
[2]])
This is more elegant syntax (and, I
I think you just can't use newaxis in advanced indexing (doc says The
newaxishttp://docs.scipy.org/doc/numpy/reference/arrays.indexing.html#numpy.newaxisobject
can be used in the basic slicing syntax, and does not mention
newaxis in the advanced indexing part).
-=- Olivier
Le 1 février 2012
Hi Bruce,
Sorry for the delay in the answer.
Le 27/01/2012 17:28, Bruce Southey a écrit :
The output is still a covariance so do we really need yet another set
of very similar functions to maintain?
Or can we get away with a new keyword?
The idea of an additional keyword seems appealing.
Hello,
when I try in my script to divide a masked array by a scalar I get an
error. The instruction is:
sppa = sp / 100.
sp is a masked array with ndim = 3.
error is:
Traceback (most recent call last):
File /media/nethome/Work/workspace/interimEnso/src/mlBudget.py,
line 95, in module
Hi,
[I'm not sure whether this discussion belongs to numpy-discussion or
scipy-dev]
In day to day time series analysis I regularly need to look at the data
autocorrelation (acorr or acf depending on the software package).
The straighforward available function I have is
2012/2/1 martin großhauser mgroszhau...@gmail.com:
Hello,
when I try in my script to divide a masked array by a scalar I get an
error. The instruction is:
sppa = sp / 100.
sp is a masked array with ndim = 3.
error is:
Traceback (most recent call last):
File
Hi all,
here's something I don't understand. Consider the following code snippet:
---
class A(object):
def __radd__(self, other):
print(type(other))
import numpy as np
np.complex64(1j) + A()
On Wed, Feb 1, 2012 at 12:26 PM, Andreas Kloeckner
li...@informa.tiker.netwrote:
Hi all,
here's something I don't understand. Consider the following code snippet:
---
class A(object):
def __radd__(self, other):
print(type(other))
2012/2/1 martin großhauser mgroszhau...@gmail.com
2012/2/1 martin großhauser mgroszhau...@gmail.com:
Hello,
when I try in my script to divide a masked array by a scalar I get an
error. The instruction is:
sppa = sp / 100.
sp is a masked array with ndim = 3.
error is:
Hi All,
Two things here.
1) Some macros for threading and the iterator now require a trailing
semicolon. This change will be reverted before the 1.7 release so that
scipy 0.10 will compile, but because it is desirable in the long term it
would be helpful if folks maintaining c extensions using
Le 01/02/2012 21:09, Benjamin Root a écrit :
I can't reproduce this bug with the latest numpy from github master.
Perhaps it has been fixed by now?
Hi,
I've no idea what's going on, but here is my $0.02 contribution. I
reproduced the bug (numpy 1.5.1) with a rather minimal script. See
The macro PyArray_RemoveLargest has been replaced by PyArray_RemoveSmallest
(which seems strange), but I wonder if this documentation still makes sense.
diff --git a/doc/source/user/c-info.beyond-basics.rst b/doc/source/user/
c-info.beyond-basics.rs
index 9ed2ab3..3437985 100644
---
On Wednesday, February 1, 2012, Pierre Haessig pierre.haes...@crans.org
wrote:
Hi,
[I'm not sure whether this discussion belongs to numpy-discussion or
scipy-dev]
In day to day time series analysis I regularly need to look at the data
autocorrelation (acorr or acf depending on the software
On Wed, Feb 1, 2012 at 6:48 PM, Benjamin Root ben.r...@ou.edu wrote:
On Wednesday, February 1, 2012, Pierre Haessig pierre.haes...@crans.org
wrote:
Hi,
[I'm not sure whether this discussion belongs to numpy-discussion or
scipy-dev]
In day to day time series analysis I regularly need to
On Wed, Feb 1, 2012 at 3:29 PM, Charles R Harris
charlesr.har...@gmail.comwrote:
The macro PyArray_RemoveLargest has been replaced by
PyArray_RemoveSmallest (which seems strange), but I wonder if this
documentation still makes sense.
My impression about this code is that it went through a
On Wed, Feb 1, 2012 at 3:47 AM, Olivier Delalleau sh...@keba.be wrote:
I think you just can't use newaxis in advanced indexing (doc says The
newaxis object can be used in the basic slicing syntax, and does not
mention newaxis in the advanced indexing part).
Yes, with fancy indexing the two
On Feb 1, 2012, at 7:04 PM, Mark Wiebe wrote:
On Wed, Feb 1, 2012 at 3:29 PM, Charles R Harris charlesr.har...@gmail.com
wrote:
The macro PyArray_RemoveLargest has been replaced by PyArray_RemoveSmallest
(which seems strange), but I wonder if this documentation still makes sense.
My
On Wed, Feb 1, 2012 at 6:14 PM, Travis Oliphant tra...@continuum.io wrote:
On Feb 1, 2012, at 7:04 PM, Mark Wiebe wrote:
On Wed, Feb 1, 2012 at 3:29 PM, Charles R Harris
charlesr.har...@gmail.com wrote:
The macro PyArray_RemoveLargest has been replaced by
PyArray_RemoveSmallest (which
Thanks! What a great doc page.
-Travis
On Feb 1, 2012, at 8:31 PM, Mark Wiebe wrote:
On Wed, Feb 1, 2012 at 6:14 PM, Travis Oliphant tra...@continuum.io wrote:
On Feb 1, 2012, at 7:04 PM, Mark Wiebe wrote:
On Wed, Feb 1, 2012 at 3:29 PM, Charles R Harris charlesr.har...@gmail.com
Hey Mark,
I spent some quality time with your iterator docs tonight and look forward to
getting into the code a bit more soon. I wanted to get your general
impressions about what it would take to extend the iterator API to handle
iterating over regions of the inputs --- i.e. to support
This seems odd to me. Unraveling what is going on (so far):
Let a = np.complex64(1j) and b = A()
* np.complex64.__add__ is calling np.add
* np.add(a, b) needs to search for an add loop that matches the input
types and it finds one with signature
Bump...
On Mon, Jan 30, 2012 at 1:17 AM, Warren Weckesser
warren.weckes...@enthought.com wrote:
In the following code, numpy.sin() calls the object's sin() function:
In [2]: class Foo(object):
...: def sin(self):
...: return spam
...:
In [3]: f = Foo()
In [4]:
Hey Andreas,
As previously described: what changes the type of np.complex64(1j) during the
A() call is that when a is an array scalar it is converted to an object array
because that is the only signature that matches. During this conversion, what
is extracted from the object array is piped
23 matches
Mail list logo