|
[Date Index]
[Thread Index]
[Author Index]
Re: Selecting Sub-lists After Split
- To: mathgroup at smc.vnet.net
- Subject: [mg77460] Re: Selecting Sub-lists After Split
- From: Donald DuBois <donabc at comcast.net>
- Date: Sat, 9 Jun 2007 05:35:03 -0400 (EDT)
> Hello everyone,
>
> Suppose I have a list of real number called myList.
> I split it into
> sub-lists of positive and negative numbers called
> myNewList by doing
> this (there may be a more elegant way):
>
> myNewList = Split[myList, #1 #2 > 0 &]
>
> Now, how can I select all of the sub-lists of
> negative numbers from
> myNewList?
>
> Any tips would be most appreciated.
>
> Regards,
>
> Gregory
>
Select[myNewList, Negative[First[#]] &]
should accomplish it.
Regards,
Don
Prev by Date:
Re: Selecting Sub-lists After Split
Next by Date:
Re: Trouble with TraditionalForm in Mathematica 6.0
Previous by thread:
Re: Selecting Sub-lists After Split
Next by thread:
Re: Selecting Sub-lists After Split
|