On Oct 12, 2010, at 1:06 AM, Pauli Virtanen wrote:
Mon, 11 Oct 2010 23:30:31 +0200, Pierre GM wrote:
Would any of you mind giving me commit rights on github? My handle is
pierregm. Thanks a million in advance.
Granted.
Got it, thanks again!
P
On Oct 7, 2010, at 4:48 AM, Chris Fonnesbeck wrote:
The documentation for loadtxt and genfromtxt state that the unpack
argument functions as follows:
If True, the returned array is transposed, so that arguments may be
unpacked using x, y, z = loadtxt(...).
Provided that all the columns
On Oct 7, 2010, at 3:49 PM, Benjamin Root wrote:
I understand the technicalities of why this occurs, but from a user's
perspective, he is asking for distinct numpy arrays of specified types. The
transposing seems to be almost an unimportant implementation detail because
the user is
Just asking,
Should I backport some bugs that were corrected in 2.0 for numpy.ma ? I don't
have any particular in mind, but I'm sure there must be some...
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
On Oct 7, 2010, at 4:01 PM, Chris Fonnesbeck wrote:
On Thu, Oct 7, 2010 at 4:00 AM, Pierre GM pgmdevl...@gmail.com wrote:
On Oct 7, 2010, at 4:48 AM, Chris Fonnesbeck wrote:
The documentation for loadtxt and genfromtxt state that the unpack
argument functions as follows:
If True
On Oct 1, 2010, at 11:26 AM, Sebastian Haase wrote:
Hi,
I'm trying to add a 'meta' attribute to ndarray to keep track of image
data filenames and resolution etc.
Following the excellent document
http://docs.scipy.org/doc/numpy/user/basics.subclassing.html
this worked right away.
On Oct 1, 2010, at 1:03 PM, Sebastian Haase wrote:
However, I had done this before for some specific image-file-types:
those would add there own attribute to ndarray array (e.g. arr.Mrc)
Now if I call the new ndarray_meta on my ndarray_with_mrc I loose the
`Mrc` attribute, leaving only the
On Sep 29, 2010, at 11:01 PM, Gökhan Sever wrote:
Hello,
Consider these two simple masked arrays:
I[188]: a = np.ma.masked_equal([1,2,3], value=2)
I[189]: b = np.ma.masked_equal([4,3,2], value=2)
An operation like this voids the mask:
I[190]: np.append(a,b)
O[190]:
On Sep 29, 2010, at 11:46 PM, josef.p...@gmail.com wrote:
any of the ma stack array function might also work, or not?
In np.ma.extras ? Most likely, yes
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
On Sep 30, 2010, at 12:15 AM, Gökhan Sever wrote:
On Wed, Sep 29, 2010 at 5:09 PM, Pierre GM pgmdevl...@gmail.com wrote:
On Sep 29, 2010, at 11:46 PM, josef.p...@gmail.com wrote:
any of the ma stack array function might also work, or not?
In np.ma.extras ? Most likely, yes
On Sep 21, 2010, at 2:25 PM, Andrew Jaffe wrote:
Hi all,
I've got an ascii file with a relatively complicated structure,
originally written by fortran with the format:
135format(a12,1x,2(f10.5,1x),i3,1x,4(f9.3,1x),4(i2,1x),3x,
1
On Sep 20, 2010, at 11:09 PM, Benjamin Root wrote:
And also if the inner execution could be clarified by asanyarray assertion
why there is ma equivalent array operation functions?
That is a design question for the numpy gods...
Well, asanyarray is not always a panacea, and can lead
On Sep 17, 2010, at 2:40 PM, Neil Hodgson wrote:
oops, I meant to save my post but I sent it instead - doh!
In the end, the question was; is worth adding start= and stop= markers into
loadtxt to allow grabbing sections of a file between two known headers? I
imagine it's something that
On Sep 15, 2010, at 11:01 AM, Mark Bakker wrote:
Hello List,
Can I make a view of an entire array but with a different shape?
For example:
a = zeros((2,3,4))
Mark,
Try that.
b = a.reshape((2,12))
Now,
b.flat=1
a
array([[[ 1., 1., 1., 1.],
[ 1., 1., 1., 1.],
On Sep 11, 2010, at 9:53 PM, Massimo Di Stefano wrote:
have you hints on how to get working the MASK code ?
as it is now it pick all the points in the mydata array.
Brett's code for the mask matched the loop of your post. However, taking a
second look at it, I don't see why it would work.
On Sep 4, 2010, at 4:35 AM, John Salvatier wrote:
Hello,
I recently had to get data from a mysql database into a recarray. The result
was not very long but nontrivial to figure out:
def recarray_from_db(db, command):
executes a command and turns the results into a numpy recarray
On Aug 23, 2010, at 10:50 AM, Emma Willemsma wrote:
I have attached a short script and sample text file that demonstrate the
problem. The dtype I'm using in the example is:
dtype2 =
numpy.dtype([((Amps,Current),f8),((Volts,Voltage),f8),((Watts,Power),f8)])
When I run the code as-is, I
On Aug 17, 2010, at 12:27 PM, Alan G Isaac wrote:
On 8/17/2010 12:07 PM, Pierre GM wrote:
What does a np.ma.test() give you ?
No problems. (Aren't those always run?)
Alan
Yes, but I just wanted to check whether I was to blame for not having ported
some changes to the 1.5.x branch
On Aug 10, 2010, at 9:54 PM, Charles R Harris wrote:
Hi Pierre,
I'm getting these tests errors now.
I forgot to commit some last minute modifications... And now (r8621) ?
Thinking about it, the function `flatnotmasked_contiguous` outputs a list of
slices, except when there's none (and then
On Aug 8, 2010, at 10:37 PM, Geordie McBain wrote:
The function numpy.ma.flatnotmasked_contiguous returns slices which
miss the last element; for example, based on the example at
http://docs.scipy.org/doc/numpy/reference/generated/numpy.ma.flatnotmasked_contiguous.html,
OK, mind opening a
On Aug 5, 2010, at 8:45 AM, Ralf Gommers wrote:
Hi all,
I'm looking at what needs to be deprecated/removed and have a few questions:
1. ma.core has some deprecations without version info:
make_mask: flag keyword
MaskedArray.flag
MaskedArray.raw_data
allclose: fillvalue
On Jul 28, 2010, at 7:52 PM, Pauli Virtanen wrote:
Wed, 28 Jul 2010 18:43:30 -0400, Pierre GM wrote:
[clip]
Mmh. I did create a PyMappingMethod structure called MyArray_as_mapping,
and MyArray_as_mapping.mp_subscript points to the function that I want
to use. However, I'd like
All,
I'm teaching myself how to subclass ndarrays in C (not in Cython, just plain
C). It's slowly coming together, but I'm now running into a problem: I need to
overwrite __getitem__ and I'm not sure how to do it. I was thinking about using
my own function instead of
On Jul 21, 2010, at 4:22 PM, wheres pythonmonks wrote:
However: is there an automatic way to convert a named index to a position?
What about looping over tuples of my recarray:
for t in d:
date = t['Date']
Why don't you use zip ?
for (date, t) in (d['Date'], d)
That way,
On Jul 21, 2010, at 4:35 PM, wheres pythonmonks wrote:
What about:
idx_by_name = dict(enumerate(d.dtype.names))
Then I can look up the index of the columns I want before the loop,
and then access by the index during the loop.
Sure. Why don't you try both approaches, time them and
On Jun 29, 2010, at 1:41 PM, Martin Janousek wrote:
Hi,
I have a Python code working on MaskedArray which can produce arrays
of a number of different shapes and ranks. In an extreme case I get
an array constructed from a scalar:
x=numpy.ma.array(333.,mask=False)
Until the recent
On Jun 20, 2010, at 7:43 PM, Pierre GM wrote:
On Jun 20, 2010, at 7:28 PM, Bevan Jenkins wrote:
I downloaded the git branch,
FYI http://github.com/pierregm/scikits.timeseries-sandbox /FYI
I had to use the Download
pierregm/scikits.timeseries-sandbox at master via a zip file as I have
On Jun 21, 2010, at 5:38 PM, Bevan Jenkins wrote:
Pierre GM pgmdevlist at gmail.com writes:
I just pushed the weekend's changes, including a fix for your problem.
Now it should be possible to define an array of dates w/ a timestep
different from 1:
date_array(start_date=Date(T, 2010
On Jun 20, 2010, at 7:28 PM, Bevan Jenkins wrote:
I downloaded the git branch, I had to use the Download
pierregm/scikits.timeseries-sandbox at master via a zip file as I have not
managed to get Git to work at Uni yet.
After deleting the old scikit I built and installed the new version
On Jun 19, 2010, at 1:50 PM, Charles R Harris wrote:
Hi All,
I'm looking at ticket #1455. At the moment I've added the ddof keyword to cov
and corrcoef and set it up so that it overrides the bias keyword when ddof is
something other than its current default of None. The question is,
On Jun 10, 2010, at 7:16 PM, Bevan Jenkins wrote:
Hello,
I have posted previously about dates prior to 1900 but this seems to be a
seperate issue. The error message is definitley different.
I can not seem to convert a timseseries from one frequency ('D') to another
('H') when i use dates
Wes,
Sorry to contact you directly. I answered to this ad on 05/24, sending a cover
letter and a link to my resume to Matt. However, I didn't get any news since.
Do you mind telling me how to check the status of my application ? If it is
rejected, so it goes, but I'd still like to know.
In
Oops, somebody should double check who's in copy before sending his emails...
Sorry about the noise all.
However, feel free to contact me offlist w/ your ideas regarding handling time
series in numpy.
All my apologies again.
P.
___
NumPy-Discussion
On Jun 10, 2010, at 7:16 PM, Bevan Jenkins wrote:
Hello,
I have posted previously about dates prior to 1900 but this seems to be a
seperate issue. The error message is definitley different.
I can not seem to convert a timseseries from one frequency ('D') to another
('H') when i use dates
I'm about to commit some changes in the numpy trunk regarding the masked
constant. Namely, 'masked' is now its own object. It inherits from MaskedArray,
but doesn't have a fill_value and is represented slightly differently:
repr(ma.masked)
'masked'
The reason behind that is to reduce the
On May 13, 2010, at 11:51 PM, Vincent Davis wrote:
Because the use of `missing` is deprecated (try to use anything but '' for
missing, and you'll get a deprecation warning).
Use `missing_values` instead.
I wasn't using 'missing' but was wondering what it did.
@Pierre, Stéfan van der Walt
On May 13, 2010, at 11:06 PM, Vincent Davis wrote:
Maybe I am missing something but it does not appear that missing='' is
documented although it is shown s an argument ?
Because the use of `missing` is deprecated (try to use anything but '' for
missing, and you'll get a deprecation warning).
On May 8, 2010, at 9:51 PM, Gökhan Sever wrote:
On Sat, May 8, 2010 at 9:29 PM, Eric Firing efir...@hawaii.edu wrote:
On 05/08/2010 04:16 PM, Ryan May wrote:
On Sat, May 8, 2010 at 7:52 PM, Gökhan Severgokhanse...@gmail.com wrote:
AttributeError: can't set attribute
Why this
On Apr 23, 2010, at 12:45 PM, josef.p...@gmail.com wrote:
Is there a reason why ma.std(ddof=1) does not calculated the std if
there are 2 valid values?
Bug! Good call... Should be fixed in SVN r8370.
___
NumPy-Discussion mailing list
On Apr 2, 2010, at 1:08 AM, Nathaniel Peterson wrote:
Is this behavior of masked arrays intended, or is it a bug?
It's not a bug, it's an unfortunate side effect of using boolean masked arrays
for indices. Don't. Instead, you should fill the masked arrays with either True
or False
On Apr 5, 2010, at 2:36 PM, Nathaniel Peterson wrote:
Pierre, Thank you for the wonderful explanation.
I get it! np.alltrue(idx.data == idx2.data) is False.
PS. Thank you for closing ticket #1447; sorry for the trouble.
No problem whatsoever. Thanks for your patience...
On Mar 28, 2010, at 4:47 PM, Andrea Gavana wrote:
HI All,
On 28 March 2010 19:22, Robert Kern wrote:
On Sun, Mar 28, 2010 at 03:26, Anne Archibald peridot.face...@gmail.com
wrote:
On 27 March 2010 20:24, Andrea Gavana andrea.gav...@gmail.com wrote:
Hi All,
I have an interpolation
All,
I'm surprised by the renaming of numpy.lib.io to numpy.lib.npyio. Was it really
necessary ? Is it to take effect with the incoming numpy 2.0 release ? BTW,
when is it scheduled ?
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
On Mar 26, 2010, at 4:36 PM, Robert Kern wrote:
On Fri, Mar 26, 2010 at 15:29, Pierre GM pgmdevl...@gmail.com wrote:
All,
I'm surprised by the renaming of numpy.lib.io to numpy.lib.npyio. Was it
really necessary ?
http://mail.scipy.org/pipermail/numpy-discussion/2010-March/049543.html
On Mar 18, 2010, at 4:12 PM, Eric Firing wrote:
Ryan May wrote:
On Thu, Mar 18, 2010 at 2:46 PM, Christopher Barker
chris.bar...@noaa.gov wrote:
Gael Varoquaux wrote:
On Thu, Mar 18, 2010 at 12:12:10PM -0700, Christopher Barker wrote:
sure -- that's kind of my point -- if EVERY numpy array
On Mar 17, 2010, at 3:18 PM, josef.p...@gmail.com wrote:
On Wed, Mar 17, 2010 at 3:12 PM, Christopher Barker
chris.bar...@noaa.gov wrote:
One of the things I liked about MATLAB was that NaNs were well handled
almost all the time. Given all the limitations of NaN, having a masked
array is a
On Mar 17, 2010, at 5:43 PM, Charles R Harris wrote:
On Wed, Mar 17, 2010 at 3:13 PM, Darren Dale dsdal...@gmail.com wrote:
On Wed, Mar 17, 2010 at 4:48 PM, Pierre GM pgmdevl...@gmail.com wrote:
On Mar 17, 2010, at 8:19 AM, Darren Dale wrote:
I started thinking about a third method
On Mar 17, 2010, at 9:16 PM, Charles R Harris wrote:
On Wed, Mar 17, 2010 at 7:39 PM, Darren Dale dsdal...@gmail.com wrote:
On Wed, Mar 17, 2010 at 8:22 PM, Charles R Harris
charlesr.har...@gmail.com wrote:
What bothers me here is the opposing desire to separate ufuncs from their
On Mar 18, 2010, at 11:03 AM, Bruce Southey wrote:
On 03/17/2010 04:20 PM, Pierre GM wrote:
On Mar 17, 2010, at 11:09 AM, Bruce Southey wrote:
On 03/17/2010 01:07 AM, Pierre GM wrote:
All,
As you're probably aware, the current test suite for numpy.ma raises some
nagging warnings
On Mar 17, 2010, at 8:19 AM, Darren Dale wrote:
I started thinking about a third method called __input_prepare__ that
would be called on the way into the ufunc, which would allow you to
intercept the input and pass a somehow modified copy back to the
ufunc. The total flow would be:
1)
On Mar 13, 2010, at 3:51 PM, josef.p...@gmail.com wrote:
I was trying to find out what the helpful message
TypeError: expected a readable buffer object means
and it seems genfromtxt has problems identifying long integers (at
least on Windows 32)
np.array(416068,int)
Traceback (most
On Mar 8, 2010, at 1:55 PM, Tim Michelsen wrote:
Hello,
I am also looking into the convertsion from strcutured arrays to ndarray.
I've just started playing with numpy and have noticed that when printing
a structured array that the output is not nicely formatted. Is there a
way to make the
On Mar 5, 2010, at 4:38 AM, David Goldsmith wrote:
Hi! Sorry for the cross-post, but my own investigation has led me to suspect
that mine is actually a numpy problem, not a matplotlib problem. I'm getting
the following traceback from a call to matplotlib.imshow:
...
Based on examination
On Mar 1, 2010, at 10:04 AM, Martin Raspaud wrote:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hi all,
We are using at the moment a c extension which should manipulate masked
arrays.
What we do is to fill the masked array with a given value (say 65535 if we run
uint16 arrays), do the
On Mar 1, 2010, at 10:39 AM, Martin Raspaud wrote:
Hi,
We're talking map projections, so that means that the values will move around,
including masked ones...
So filling the array with a given value is a way of projecting the array and
the
mask in one shot...
OK then. Just make sure
On Feb 28, 2010, at 8:59 PM, Peter Shinners wrote:
I have a 2D masked array that has indices into a 1D array. I want to use
some form of take to fetch the values into the 2D array. I've tried
both numpy.take and numpy.ma.take, but they both return a new unmasked
array.
Mmh. Surprising.
On Feb 28, 2010, at 11:12 PM, Charles R Harris wrote:
__
Ah, Pierre, now that you are here... ;) Can you take a look at the invalid
value warnings in the masked array tests and maybe fix them up by turning
off the warnings where appropriate? I'd do it myself except that I hesitate
On Mar 1, 2010, at 1:02 AM, Peter Shinners wrote:
Here is the code as I would like it to work.
http://python.pastebin.com/CsEnUrSa
import numpy as np
values = np.array((40, 18, 37, 9, 22))
index = np.arange(3)[None,:] + np.arange(5)[:,None]
mask = index = len(values)
maskedindex =
On Feb 26, 2010, at 12:42 PM, Sam Tygier wrote:
On Fri, 2010-02-26 at 07:56 +, numpy-discussion-requ...@scipy.org
wrote:
Date: Thu, 25 Feb 2010 13:56:43 -0800
From: Chris Barker chris.bar...@noaa.gov
if not, I'd use the std lib csv module, then convert to numpy arrays,
not as
On Feb 15, 2010, at 8:51 PM, David Carmean wrote:
On Sun, Feb 14, 2010 at 03:22:04PM -0500, Pierre GM wrote:
I'm sorry, I can't follow you. Can you post a simpler self-contained example
I can play with ?
Why using np.nanmin/max ? These functions are designed for ndarrays, to
avoid using
It has been suggested (ticket #1262) to change the default dtype=float to
dtype=None in np.genfromtxt. Any thoughts ?
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
http://mail.scipy.org/mailman/listinfo/numpy-discussion
On Feb 14, 2010, at 7:47 AM, Neil Crighton wrote:
Pierre GM pgmdevlist at gmail.com writes:
It has been suggested (ticket #1262) to change the default dtype=float to
dtype=None in np.genfromtxt.
Any thoughts ?
I agree dtype=None should be default for the reasons given in the ticket
On Feb 13, 2010, at 10:04 PM, David Carmean wrote:
I'm just starting to work with masked arrays and I've found some behavior
that
definitely does not follow the Principle of Least Surprise:
A fuzzy concept ;)
I've generated a 2-d array from a list of lists, where the elements are
On Feb 14, 2010, at 12:02 PM, Charles R Harris wrote:
Python 2.4
==
ERROR: test_view_to_flexible_dtype (test_core.TestMaskedView)
--
Traceback (most
On Feb 12, 2010, at 11:01 PM, David Goldsmith wrote:
On Fri, Feb 12, 2010 at 7:09 PM, Pierre GM pgmdevl...@gmail.com wrote:
On Feb 12, 2010, at 8:14 PM, David Goldsmith wrote
Is the present issue an instance where Scott's second statement is invalid,
an instance where its validity
On Feb 14, 2010, at 1:26 AM, Charles R Harris wrote:
*All* the buildbots are showing errors. Here are some:
Only with Python 2.4, right ? That's the ticket #1367 I haven't had time to
deal with (because I need a Python2.4 to test it).
___
On Feb 14, 2010, at 1:42 AM, David Goldsmith wrote:
On Sat, Feb 13, 2010 at 9:53 PM, Pierre GM pgmdevl...@gmail.com wrote:
On Feb 13, 2010, at 11:56 PM, David Goldsmith wrote:
Please don't misinterpret my statements to mean that I think this isn't
important and/or that you should feel
On Feb 14, 2010, at 2:03 AM, Charles R Harris wrote:
On Sat, Feb 13, 2010 at 11:50 PM, Pierre GM pgmdevl...@gmail.com wrote:
On Feb 14, 2010, at 1:26 AM, Charles R Harris wrote:
*All* the buildbots are showing errors. Here are some:
Only with Python 2.4, right ? That's the ticket
On Feb 12, 2010, at 4:24 PM, David Goldsmith wrote:
OK, OK, Ok, it's not worth getting into a flame war over. We ask people who
are going to be working on the docstrings to subscribe to scipy-dev; this is
not the same thing as being an innocent bystander asking a question or
making a
On Feb 12, 2010, at 8:14 PM, David Goldsmith wrote
Is the present issue an instance where Scott's second statement is invalid,
an instance where its validity is resulting in a poor docstring for the
function, or an instance in which Scott's recommendation was not followed?
The methods'
On Feb 11, 2010, at 5:57 PM, David Cournapeau wrote:
On Fri, Feb 12, 2010 at 2:04 AM, Charles R Harris
charlesr.har...@gmail.com wrote:
2010/2/11 Stéfan van der Walt ste...@sun.ac.za
On 11 February 2010 15:38, Darren Dale dsdal...@gmail.com wrote:
2010/2/11 Stéfan van der Walt
On Feb 10, 2010, at 11:10 AM, John Hunter wrote:
On Wed, Feb 10, 2010 at 8:54 AM, John Hunter jdh2...@gmail.com wrote:
On Tue, Feb 9, 2010 at 7:53 PM, Pierre GM pgmdevl...@gmail.com wrote:
On Feb 9, 2010, at 8:16 PM, John Hunter wrote:
and have totxt, tocsv. etc... from rec2txt, rec2csv, etc
On Feb 10, 2010, at 3:31 PM, Travis Oliphant wrote:
The list I proposed for deciding the issue was the group I am aware of having
written significant code for NumPy.I suppose I un-intentionally left off
Pierre GM who contributed masked array support. We need some way of
making
On Feb 10, 2010, at 4:57 PM, David Carmean wrote:
I still can't figure out what to import/how to get to numpy.lib.recfunctions.
Maybe I don't yet understand the scipy/numpy/matplotlib package structure?
Nope, that's not a standard one:
import numpy.lib.recfunctions as recf
On Feb 10, 2010, at 7:26 PM, David Carmean wrote:
Got this to work, but now it's revealed my lack of understanding of the
shape
of arrays; I'd hoped that the results would look like (be the same shape
as?)
the column_stack results.
You're misunderstanding what structured arrays /
On Feb 9, 2010, at 6:52 PM, Robert Kern wrote:
On Tue, Feb 9, 2010 at 17:47, Ralf Gommers ralf.gomm...@googlemail.com
wrote:
On Wed, Feb 10, 2010 at 6:02 AM, Robert Kern robert.k...@gmail.com wrote:
For some reason, numpy.lib.recfunctions isn't in the documentation
editor. I'm not
On Feb 9, 2010, at 7:54 PM, Pauli Virtanen wrote:
But, should we make these functions available under some less
internal-ish namespace? There's numpy.rec at the least -- it could be
made a real module to pull in things from core and lib.
I still think these functions are more generic than
On Feb 9, 2010, at 8:16 PM, John Hunter wrote:
I still think these functions are more generic than the rec_ prefix let
think, and I'd still prefer a decision being made about what should go in
the module before thinking too hard about how to advertise it.
I would love to see many of these
On Jan 27, 2010, at 9:10 PM, Keith Goodman wrote:
I recently opened sourced one of my packages. It is a labeled array
that I call larry.
A two-dimensional larry, for example, contains a 2d NumPy array with
labels on each row and column. A larry can have any dimension.
Alignment by label
On Jan 21, 2010, at 5:27 PM, David Cournapeau wrote:
On Fri, Jan 22, 2010 at 7:14 AM, David Cournapeau courn...@gmail.com wrote:
On Fri, Jan 22, 2010 at 12:06 AM, Charles R Harris
charlesr.har...@gmail.com wrote:
On Thu, Jan 21, 2010 at 3:03 AM, David Cournapeau courn...@gmail.com
wrote:
On Jan 20, 2010, at 4:57 PM, Darren Dale wrote:
I haven't been following development on the trunk closely, so I
apologize if this is a known issue. I didn't see anything relevant
when I searched the list.
I just updated my checkout of the trunk, cleaned out the old
installation and build/,
On Jan 14, 2010, at 11:06 PM, David Cournapeau wrote:
On Fri, Jan 15, 2010 at 11:59 AM, Pierre GM pgmdevl...@gmail.com wrote:
On Jan 14, 2010, at 8:52 PM, David Cournapeau wrote:
Pierre GM wrote:
Er, no.
np.ma.minimum(a, b) returns the lowest value of a and b element-wsie
On Jan 14, 2010, at 8:52 PM, David Cournapeau wrote:
Pierre GM wrote:
Er, no.
np.ma.minimum(a, b) returns the lowest value of a and b element-wsie, or the
the lowest element of a is b is None. The behavior is inherited from the
very first implementation of maskedarray in numeric
On Jan 12, 2010, at 10:52 AM, stephen.pas...@stfc.ac.uk
stephen.pas...@stfc.ac.uk wrote:
We have noticed the MaskedArray implementation in numpy-1.4.0 breaks
some of our code. For instance we see the following:
My, that's embarrassing. Sorry for the inconvenience.
in 1.3.0:
a =
On Jan 12, 2010, at 1:52 PM, Charles R Harris wrote:
On Tue, Jan 12, 2010 at 11:32 AM, Pauli Virtanen p...@iki.fi wrote:
ti, 2010-01-12 kello 12:51 -0500, Pierre GM kirjoitti:
[clip]
a = numpy.ma.MaskedArray([[1,2,3],[4,5,6]])
numpy.ma.sum(a, 1)
Traceback (most recent call last
On Jan 11, 2010, at 5:10 AM, Tim Michelsen wrote:
Hello,
I experienced the following issue with numpy 1.4:
...
Is this an error in numpy or no the other packages require update in the code?
Let me guess, you just recently updated numpy ? I'd bet ybut forgot to
recompile scipy and
On Jan 5, 2010, at 12:32 PM, Christopher Barker wrote:
josef.p...@gmail.com wrote:
On Mon, Jan 4, 2010 at 10:39 PM, a...@ajackson.org wrote:
I rather like the R command(s) for reading text files
Aren't the newly improved
numpy.genfromtxt()
...
and friends indented to handle all
On Jan 5, 2010, at 3:45 PM, Eric Firing wrote:
neil weisenfeld wrote:
Hi all,
I'm having an odd problem with the package installer for numpy 1.4.0.
It complains:
numpy 1.4.0 can't be installed on this disk. numpy requires System
Python 2.6 to install.
I think the problem is that the
On Jan 5, 2010, at 6:22 PM, David Warde-Farley wrote:
On 5-Jan-10, at 6:01 PM, Christopher Barker wrote:
The python.org python is the best one to support -- Apple has never
upgraded a python, has often shipped a broken version, and has
provided
different versions with each OS-X version.
All,
* What is the most efficient way to get a np.void object from a 0d structured
ndarray ?
* Is there any way to subclass np.void ?
Thanks a lot in advance !
P.
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
On Dec 17, 2009, at 10:16 AM, Francesc Alted wrote:
A Thursday 17 December 2009 15:16:29 Pierre GM escrigué:
All,
* What is the most efficient way to get a np.void object from a 0d
structured ndarray ?
I normally use `PyArray_GETITEM` C macro for general n-d structured arrays.
I
On Dec 17, 2009, at 6:35 PM, Robert Kern wrote:
On Thu, Dec 17, 2009 at 16:11, Pierre GM pgmdevl...@gmail.com wrote:
On Dec 17, 2009, at 10:16 AM, Francesc Alted wrote:
A Thursday 17 December 2009 15:16:29 Pierre GM escrigué:
All,
* What is the most efficient way to get a np.void object from
On Dec 14, 2009, at 4:28 PM, Thomas Robitaille wrote:
Pierre GM-2 wrote:
Well, that's a problem indeed, and I'd put that as a bug.
However, you can use that syntax instead:
t.fill_value['a']=10
or set all the fields at once:
t.fill_value=(10,99)
Thanks for your reply - should I
On Dec 13, 2009, at 12:11 AM, Robert Ferrell wrote:
Have you considered creating a TimeSeries for each data series, and
then putting them all together in a dict, keyed by symbol?
That's an idea
One disadvantage of one big monster numpy array for all the series is
that not all series may
On Dec 13, 2009, at 6:18 PM, Thomas Robitaille wrote:
Hi,
The following code doesn't seem to work:
import numpy.ma as ma
t = ma.array(zip([1,2,3],[4,5,6]),dtype=[('a',int),('b',int)])
print repr(t['a'])
t['a'].set_fill_value(10)
print repr(t['a'])
As the output is
On Dec 13, 2009, at 8:54 PM, Ernest Adrogué wrote:
Hi,
How does one generate a structured array from a normal
array?
I use the 'view' method, but this way I get a superfluous
dimension that I do not want. Example:
In [619]: a = np.array([[1,2,3],[1,2,3],[1,2,4]],int)
In [620]:
On Dec 8, 2009, at 2:31 AM, David Cournapeau wrote:
Pierre GM wrote:
A bit of background first;
In the first implementations of numpy.core.ma, the approach was to get rid
of the data that could cause problem beforehand by replacing them with safe
values. Turned out that finding these data
On Dec 8, 2009, at 3:42 PM, John [H2O] wrote:
I see record arrays don't have a masked_where method. How can I achieve the
following for a record array:
cd.masked_where(cd.co == -.)
Or something like this.
masked_where is a function that requires 2 arguments.
If you try to mask a
On Dec 8, 2009, at 4:36 PM, Robert Kern wrote:
err_status_ini = np.geterr()
np.seterr(divide='ignore', invalid='ignore')
result = self.f(da, db, *args, **kwargs)
np.seterr(**err_status_ini)
Is this kind of fix acceptable ?
olderr =
On Dec 8, 2009, at 4:53 PM, John [H2O] wrote:
This is what I get:
In [74]: type(cd)
Out[74]: class 'numpy.core.records.recarray'
In [75]: type(cd.co)
Out[75]: type 'numpy.ndarray'
In [76]: cd[cd['co']==-.] = np.ma.masked
101 - 200 of 659 matches
Mail list logo