MathGroup Archive 2012

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

Search the Archive

Re: Replace, ReplaceAll and If time performace comparition


Hi,

  congratulations!

  It strikes the performance of Clip on my machine by a factor of 2 
(instead of
a factor of 1.45 as published in my previous post).

Does it mean, that Compile + Map + raw functions is a good combination 
to speed up codes?


Question: Can anyone explain, why RuntimeOptions->"Speed" does not 
improve the performance?


Thanks for your code,

   Christoph



On 06/28/2012 10:02 AM, awnl wrote:
> Hi,
>
>> Can anyone top the result?
> contradicting to my announcement, I tried anyway and found this to be
> considerably faster on my machine:
>
> cf3 = Compile[{{list, _Integer, 1}},
>    Map[If[# > 0, #, 0] &, list],
>    CompilationTarget -> "C"
> ]
>
> hth,
>
> albert
>





  • Prev by Date: Re: Extracting Information from XBRL Files
  • Next by Date: Re: Approximate Zero Times A Symbol
  • Previous by thread: Re: Replace, ReplaceAll and If time performace comparition
  • Next by thread: Re: Replace, ReplaceAll and If time performace comparition