Re: Remove Indeterminate elements
- To: mathgroup at smc.vnet.net
- Subject: [mg64296] Re: [mg64280] Remove Indeterminate elements
- From: Bob Hanlon <hanlonr at cox.net>
- Date: Fri, 10 Feb 2006 02:13:32 -0500 (EST)
- Reply-to: hanlonr at cox.net
- Sender: owner-wri-mathgroup at wolfram.com
x={{1,2},{Indeterminate,3.},{3.,4},
{2,Indeterminate},{5,6.},
{Indeterminate,Indeterminate},{7.,8.}};
Cases[x, {_?NumericQ,_?NumericQ}]
{{1, 2}, {3., 4}, {5, 6.}, {7., 8.}}
Other methods:
%==Select[x, FreeQ[#,Indeterminate]&]==
DeleteCases[x,_?(!FreeQ[#,Indeterminate]&)]==
DeleteCases[x,_?(MemberQ[#,Indeterminate]&)]
True
Bob Hanlon
>
> From: "Baris Erbas" <berbas at anadolu.edu.tr>
To: mathgroup at smc.vnet.net
> Subject: [mg64296] [mg64280] Remove Indeterminate elements
>
>
> Dear All,
>
> I have been trying to remove some elements of a list which should be quite
> straightforward. The list is as follows:
>
> {{x1,y1},{x2,y2},.{xi,yi},{Indeterminate,Indeterminate},.{xn,yn}}. All the
> components are real numbers apart from some Indeterminate expressions.
I
> want the list without the Indeterminate terms. I have been trying to use
> Delete with If command but cannot succeed.
>
> Can anyone help please?
>
> Thanks
>
>