MathGroup Archive 2010

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

Search the Archive

Re: Speed Up Routines

  • To: mathgroup at smc.vnet.net
  • Subject: [mg109377] Re: Speed Up Routines
  • From: "Benedetto Bongiorno" <bongiob at sbcglobal.net>
  • Date: Sat, 24 Apr 2010 04:01:17 -0400 (EDT)

Bob,

What kind of data is stored in "data" and "cntrlUnits"? 
Dimensions of "data" is 370161 x 15
"data "are columns of real values and strings
"cntrlUnits" are strings

"headings02"?
Numerical column identification, i.e. "6"


Thank You

Benedetto Bongiorno CPA CRE
Cell 214-707-6546
Land 972-470-9138
Fax 972-470-9748
bongiob at sbcglobal.net

This Email is covered by the Electronic Communications Privacy Act, 18
U.S.C. Sections 2510-2521 and is legally privileged. The information
contained in this Email is intended only for the use of the individual
or entity named above. If the reader of this message is not the intended
recipient, you are hereby notified that any dissemination, distributions
or copying of this communication is strictly prohibited. If you have
received this communication in error, please notify sender.


-----Original Message-----
From: DrMajorBob [mailto:btreat1 at austin.rr.com] 
Sent: Friday, April 23, 2010 10:20 AM
To: Benedetto Bongiorno; mathgroup at smc.vnet.net
Subject: [mg109377] Re: [mg109361] Speed Up Routines

What kind of data is stored in "data" and "cntrlUnits"?

What are the dimensions and data type of "headings02"?

Could we see a short example of each?

Without any of that, how can we tell what you're trying to accomplish?

Bobby

On Fri, 23 Apr 2010 02:49:23 -0500, Benedetto Bongiorno  
<bongiob at sbcglobal.net> wrote:

> Mathgroup,
>
>
> I have the following routines that take approx 5 minutes.
>
> Can you give me suggestions to implement MAP in the areas of For
>
>
> Length[data]
>
> 370161
>
> Length[cntrlUnits}
>
> 456
>
>
> n=Length[cntrlUnits]+1;
>
> cntrlUnitsData=Table[0,{i,1,Length[cntrlUnits]}];
>
>
For[i=1,i<n,i++,cntrlUnitsData[[i]]=Position[data[[All,Flatten[Position[head
> ings02,"GLICU"]][[1]]]],_?(#==cntrlUnits[[i]]&)]];
>
>
> Length[cntrlUnitsData]
>
> 456
>
>
> n=Length[cntrlUnits]+1;
>
> cntrlUnitsTrans=Table[0,{i,1,Length[cntrlUnits]}];
>
> For[i=1,i<n,i++,cntrlUnitsTrans[[i]]=Map[data[[#]]&,cntrlUnitsData[[i]]]];
>
>
> Length[cntrlUnitsTrans]
>
> 456
>
>
> Thank you,
>
>
> Benedetto Bongiorno CPA CRE
>
> Cell 214-707-6546
>
> Land 972-470-9138
>
> Fax 972-470-9748
>
> bongiob at sbcglobal.net
>
>
> This Email is covered by the Electronic Communications Privacy Act, 18
> U.S.C. Sections 2510-2521 and is legally privileged. The information
> contained in this Email is intended only for the use of the individual
> or entity named above. If the reader of this message is not the intended
> recipient, you are hereby notified that any dissemination, distributions
> or copying of this communication is strictly prohibited. If you have
> received this communication in error, please notify sender.
>
>


-- 
DrMajorBob at yahoo.com



  • Prev by Date: Stop mathematica reordering expression during matrix multiply
  • Next by Date: Re: Download as Live Mathematica from Wolfram|Alpha
  • Previous by thread: Re: Speed Up Routines
  • Next by thread: Re: Speed Up Routines