MathGroup Archive 2007

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

Search the Archive

Re: Designing a Flexible Mathematica Program for Data Analysis

  • To: mathgroup at smc.vnet.net
  • Subject: [mg74715] Re: [mg74690] Designing a Flexible Mathematica Program for Data Analysis
  • From: "Chris Chiasson" <chris at chiasson.name>
  • Date: Sun, 1 Apr 2007 04:22:49 -0400 (EDT)
  • References: <200703310637.BAA05737@smc.vnet.net>

readDataSet should probably have multiple (10) DownValues that can
transfer each of the different original data formats into an
intermediate format that can be processed by other functions

On 3/31/07, 5000brians <5000brians at gmail.com> wrote:
> I'm using Mathematica to perform data analysis for a project I've been
> working on for a few years. I have written quite a bit of Mathematica
> code for automating the task of analyzing the data.
>
> As time goes by, the type of data I collect changes slightly. I'm
> looking for a way for the various data set types I have to happily
> coexist within a single Mathematica session so I can compare and
> contrast all the data with a minimum of fuss.
>
> Let's say I want to create a plot of dataset 1 and dataset 2. In both
> cases, I want the same thing, a plot of parameter a versus parameter
> b. And let's say I have a bunch of code already written and it works
> just fine for dataset 1. But, dataset 2 is newer, and the data format
> is slightly different. The parameters a and b mean the same thing in
> both cases, it's just that they are represented differently in dataset
> 2 than in dataset 1.
>
> And let's say I have the following functions:
> readDataset: opens the text file and puts dataset into memory
> generateAandB: based on the data in the dataset, creates a list of
> parameters a and b for a dataset
> plotAandB: creates a plot of a vs b.
>
> In this case, I probably need two versions of readDataset and
> generateAandB, one for each of my dataset types. If I am using a
> List[], I am probably ok with one plotAandB function.
>
> But how can I automate this solution? What if I want to read in 30
> datasets with 10 different dataset types?
>
> I can't do plotAandB[generateAandB[readDataset[#]]]& /@
> listOfDatasets, because I need 10 different generateAandBs and 10
> different readDatasets.
>
> How can I make my code "datatype aware"?
>
> I know this is a bit long winded - sorry about that.
>
> Thanks for any help,
> Brian
>
>
>


-- 
http://chris.chiasson.name/


  • Prev by Date: Re: Closing All Input Cells at Once- KB shortcuts
  • Next by Date: Re: Designing a Flexible Mathematica Program for Data Analysis
  • Previous by thread: Re: Closing All Input Cells at Once- KB shortcuts
  • Next by thread: Re: Designing a Flexible Mathematica Program for Data Analysis