MathGroup Archive 2008

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

Search the Archive

Re: plot primes only

Hello Marcus,
This may what you are looking for:
data = Range[10]
primesdata = Select[data, PrimeQ]

Or this,

data = Table[{i, Log[i]}, {i, 1, 100000}];
primesdata = Select[data, PrimeQ[#[[1]]] &];


On Wed, May 14, 2008 at 6:06 AM, markus mooslechner
<markus.mooslechner at> wrote:
> hi everyone!
>  a quick one:
>  how can i tell mathematica to only list the primes from a list of data
>  and omit the others?
>  primeQ only tells me the boolean result
>  thanx
>  markus

W. Craig Carter

  • Prev by Date: Re: export mathematica table to .mat (MATLAB) format.Please help!!!
  • Next by Date: Re: Re: Testing TOC sidebar palette
  • Previous by thread: Re: plot primes only
  • Next by thread: Re: plot primes only