MathGroup Archive 2011

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Position

  • To: mathgroup at smc.vnet.net
  • Subject: [mg119224] Re: Position
  • From: Wolfgang Windsteiger <Wolfgang.Windsteiger at risc.jku.at>
  • Date: Wed, 25 May 2011 19:31:17 -0400 (EDT)
  • References: <irijmq$qck$1@smc.vnet.net>

Position needs a *pattern*, not a condition. Like what you would write 
in Cases[data,...] when used instead of Select[data,...] in order to 
filter elements.

WW.

On 05/25/2011 11:55 AM, Joerg Schroeder wrote:
> Dear Group,
>
> I don't understand the following:
>
> I have a list of data and want to find the position of special elements:
>
> data=Table[CDF[BinomialDistribution[150,0.3],k],{k,0,150}]
>
> Position[data,#>=0.95&]
>
> With this I get {} (null set) as an answer, whereas for example Select gives the answer I expect.
>
> Select[data,#>=0.95&]
>
> Do I do something wrong with Position?
>
> Thanks
>
> Jorg Schroder


  • Prev by Date: CreateCellID
  • Next by Date: Re: Position
  • Previous by thread: Re: Position
  • Next by thread: Re: Position