MathGroup Archive 2010

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

Search the Archive

Re: Plotting date-time series in 3D how to handle date-time to plot

  • To: mathgroup at smc.vnet.net
  • Subject: [mg106727] Re: Plotting date-time series in 3D how to handle date-time to plot
  • From: "Hans Michel" <hmichel at cox.net>
  • Date: Fri, 22 Jan 2010 05:36:29 -0500 (EST)
  • References: <hj40n2$sed$1@smc.vnet.net> <201001201149.GAA09262@smc.vnet.net> <hj985a$fto$1@smc.vnet.net>

Kurt:

I added more comments to your 3D plotting goal.

Since programming in Mathematica is different teritory for you I would like 
to suggest that you
place you questions in terms of the full project you are trying to 
accomplish.


For example post the actual line from raw data before it is massaged by any 
outside programs.

And then post your final goal.

It seems like you have built many smaller functions to perform some parts of 
you project. For example "julianDayModified". But you will find that the 
folks in this group are more than helpful when they get the entire picture.

It seems that your "hour" functions have more to do with TimeZones than 
complicated rules of
-6 and 24. If you use the timezone correctly, the date part will adjust 
accordingly.

Hans

"Canopus56" <canopus56 at yahoo.com> wrote in message 
news:hj985a$fto$1 at smc.vnet.net...
>> It seems that you are doing work in Excel anyway to get the date into a
>> Mathematica date list format. Why not keep the date in Excel internal
>> serialized date format.
>
> Thanks, Hans.  Eliminating the additional work step of having to port 
> things through Excel is one of the things I was after getting rid of.  My 
> objective was to have an efficient Mathematica on-click notebook that I 
> could just click on and then recieve and updated chart of the raw data. - 
> Kurt
>
> ----- Original Message ----
> From: Hans Michel <hmichel at cox.net>
> Sent: Wed, January 20, 2010 4:49:49 AM
> Subject:  Re: Plotting date-time series in 3D how to handle date-time to 
> plot
>
> Kurt:
>
> It seems that you are doing work in Excel anyway to get the date into a
> Mathematica date list format.
>
> Why not keep the date in Excel internal serialized date format.
> See http://www.cpearson.com/excel/datetime.htm
>
> If you wish to convert that number to Mathematica date while in 
> Mathematica
> then you can see
> http://forums.wolfram.com/mathgroup/archive/2004/May/msg00523.html
>
> ToDate[(38132 + 2)*(60*60*24)]
>
> ToDate[(excel serialdate here + 2)*(60*60*24)]
>
> If the work is already done to go from excel date to mathematica date 
> list,
> then you can look into the following functions:
> FromDate function or AbsoluteTime function in mathematica
>
> If you wish to transform the date list to Julian day then see
> http://emr.cs.iit.edu/home/reingold/calendar-book/third-edition/
>
> The Calendrica Package from edition have some serialized date formats like
> RD or JD or MJD.
>
> After serializing the dates, you will have numbers that ListPlot3D can 
> deal
> with.
>
> Hans
>
>
> "Canopus56" <canopus56 at yahoo.com> wrote in message
> news:hj40n2$sed$1 at smc.vnet.net...
>>I have a year's worth of time series data that I would like to plot in 3d
>>using ListPlot3D. ListPlot3D does not accept the system formatted dates
>>like the 2D utility DateListPlot.
>>
>> Q1. What is the best way to plot this type of time series in 3D where the
>> date-times may cross January 1 and two or more years?
>>
>> A week's worth of data is appended.
>>
>> I have previously been doing this by converting raw csv data file's
>> date-time to a Julian Day in Excel and then importing to Mathematica. I
>> would like to simplify things by doing the entire import and plot routine
>> in Mathematica directly on the raw data csv file.
>>
>> Thanks for your help. - Kurt
>>
>> lstTriple = {{{2009, 12, 15, 0, 0, 0.}, 0, -0.7252}, {{2009, 12, 15, 1, 
>> 0,
>> 0.},
>> 1, -10.926}, {{2009, 12, 15, 2, 0, 0.},
>> 2, -21.7816}, {{2009, 12, 15, 3, 0, 0.},
>> 3, -33.0166}, {{2009, 12, 15, 4, 0, 0.},
>> 4, -44.3585}, {{2009, 12, 15, 5, 0, 0.},
>> 5, -55.4223}, {{2009, 12, 15, 6, 0, 0.},
>> 6, -65.3759}, {{2009, 12, 15, 7, 0, 0.},
>> 7, -71.8831}, {{2009, 12, 15, 8, 0, 0.},
>> 8, -70.8447}, {{2009, 12, 15, 9, 0, 0.},
>> 9, -63.1364}, {{2009, 12, 15, 10, 0, 0.},
>> 10, -52.7841}, {{2009, 12, 15, 11, 0, 0.},
>> 11, -41.6044}, {{2009, 12, 15, 12, 0, 0.},
>> 12, -30.2628}, {{2009, 12, 15, 13, 0, 0.},
>> 13, -19.0995}, {{2009, 12, 15, 14, 0, 0.},
>> 14, -8.3809}, {{2009, 12, 15, 15, 0, 0.}, 15,
>> 1.6071}, {{2009, 12, 15, 16, 0, 0.}, 16,
>> 10.5065}, {{2009, 12, 15, 17, 0, 0.}, 17,
>> 17.8571}, {{2009, 12, 15, 18, 0, 0.}, 18,
>> 23.1082}, {{2009, 12, 15, 19, 0, 0.}, 19,
>> 25.72}, {{2009, 12, 15, 20, 0, 0.}, 20,
>> 25.3619}, {{2009, 12, 15, 21, 0, 0.}, 21,
>> 22.082}, {{2009, 12, 15, 22, 0, 0.}, 22,
>> 16.2805}, {{2009, 12, 15, 23, 0, 0.}, 23,
>> 8.5148}, {{2009, 12, 16, 0, 0, 0.},
>> 0, -0.6809}, {{2009, 12, 16, 1, 0, 0.},
>> 1, -10.8716}, {{2009, 12, 16, 2, 0, 0.},
>> 2, -21.7206}, {{2009, 12, 16, 3, 0, 0.},
>> 3, -32.9522}, {{2009, 12, 16, 4, 0, 0.},
>> 4, -44.2945}, {{2009, 12, 16, 5, 0, 0.},
>> 5, -55.3652}, {{2009, 12, 16, 6, 0, 0.},
>> 6, -65.3402}, {{2009, 12, 16, 7, 0, 0.},
>> 7, -71.9011}, {{2009, 12, 16, 8, 0, 0.},
>> 8, -70.9291}, {{2009, 12, 16, 9, 0, 0.},
>> 9, -63.2465}, {{2009, 12, 16, 10, 0, 0.},
>> 10, -52.9002}, {{2009, 12, 16, 11, 0, 0.},
>> 11, -41.7218}, {{2009, 12, 16, 12, 0, 0.},
>> 12, -30.38}, {{2009, 12, 16, 13, 0, 0.},
>> 13, -19.2154}, {{2009, 12, 16, 14, 0, 0.},
>> 14, -8.4942}, {{2009, 12, 16, 15, 0, 0.}, 15,
>> 1.4982}, {{2009, 12, 16, 16, 0, 0.}, 16,
>> 10.4049}, {{2009, 12, 16, 17, 0, 0.}, 17,
>> 17.7668}, {{2009, 12, 16, 18, 0, 0.}, 18,
>> 23.0345}, {{2009, 12, 16, 19, 0, 0.}, 19,
>> 25.6681}, {{2009, 12, 16, 20, 0, 0.}, 20,
>> 25.335}, {{2009, 12, 16, 21, 0, 0.}, 21,
>> 22.0799}, {{2009, 12, 16, 22, 0, 0.}, 22,
>> 16.3002}, {{2009, 12, 16, 23, 0, 0.}, 23,
>> 8.552}, {{2009, 12, 17, 0, 0, 0.},
>> 0, -0.6305}, {{2009, 12, 17, 1, 0, 0.},
>> 1, -10.8118}, {{2009, 12, 17, 2, 0, 0.},
>> 2, -21.6544}, {{2009, 12, 17, 3, 0, 0.},
>> 3, -32.8826}, {{2009, 12, 17, 4, 0, 0.},
>> 4, -44.2253}, {{2009, 12, 17, 5, 0, 0.},
>> 5, -55.3024}, {{2009, 12, 17, 6, 0, 0.},
>> 6, -65.2976}, {{2009, 12, 17, 7, 0, 0.},
>> 7, -71.9107}, {{2009, 12, 17, 8, 0, 0.},
>> 8, -71.0062}, {{2009, 12, 17, 9, 0, 0.},
>> 9, -63.3515}, {{2009, 12, 17, 10, 0, 0.},
>> 10, -53.0123}, {{2009, 12, 17, 11, 0, 0.},
>> 11, -41.8355}, {{2009, 12, 17, 12, 0, 0.},
>> 12, -30.4934}, {{2009, 12, 17, 13, 0, 0.},
>> 13, -19.3273}, {{2009, 12, 17, 14, 0, 0.},
>> 14, -8.6031}, {{2009, 12, 17, 15, 0, 0.}, 15,
>> 1.3943}, {{2009, 12, 17, 16, 0, 0.}, 16,
>> 10.309}, {{2009, 12, 17, 17, 0, 0.}, 17,
>> 17.683}, {{2009, 12, 17, 18, 0, 0.}, 18,
>> 22.9678}, {{2009, 12, 17, 19, 0, 0.}, 19,
>> 25.6237}, {{2009, 12, 17, 20, 0, 0.}, 20,
>> 25.3157}, {{2009, 12, 17, 21, 0, 0.}, 21,
>> 22.0853}, {{2009, 12, 17, 22, 0, 0.}, 22,
>> 16.3269}, {{2009, 12, 17, 23, 0, 0.}, 23,
>> 8.5956}, {{2009, 12, 18, 0, 0, 0.},
>> 0, -0.5742}, {{2009, 12, 18, 1, 0, 0.},
>> 1, -10.7464}, {{2009, 12, 18, 2, 0, 0.},
>> 2, -21.5829}, {{2009, 12, 18, 3, 0, 0.},
>> 3, -32.8081}, {{2009, 12, 18, 4, 0, 0.},
>> 4, -44.151}, {{2009, 12, 18, 5, 0, 0.},
>> 5, -55.234}, {{2009, 12, 18, 6, 0, 0.},
>> 6, -65.2482}, {{2009, 12, 18, 7, 0, 0.},
>> 7, -71.9119}, {{2009, 12, 18, 8, 0, 0.},
>> 8, -71.0759}, {{2009, 12, 18, 9, 0, 0.},
>> 9, -63.4512}, {{2009, 12, 18, 10, 0, 0.},
>> 10, -53.1202}, {{2009, 12, 18, 11, 0, 0.},
>> 11, -41.9454}, {{2009, 12, 18, 12, 0, 0.},
>> 12, -30.6029}, {{2009, 12, 18, 13, 0, 0.},
>> 13, -19.435}, {{2009, 12, 18, 14, 0, 0.},
>> 14, -8.7074}, {{2009, 12, 18, 15, 0, 0.}, 15,
>> 1.2956}, {{2009, 12, 18, 16, 0, 0.}, 16,
>> 10.2189}, {{2009, 12, 18, 17, 0, 0.}, 17,
>> 17.6057}, {{2009, 12, 18, 18, 0, 0.}, 18,
>> 22.9083}, {{2009, 12, 18, 19, 0, 0.}, 19,
>> 25.5868}, {{2009, 12, 18, 20, 0, 0.}, 20,
>> 25.304}, {{2009, 12, 18, 21, 0, 0.}, 21,
>> 22.098}, {{2009, 12, 18, 22, 0, 0.}, 22,
>> 16.3605}, {{2009, 12, 18, 23, 0, 0.}, 23,
>> 8.6455}, {{2009, 12, 19, 0, 0, 0.},
>> 0, -0.5121}, {{2009, 12, 19, 1, 0, 0.},
>> 1, -10.6756}, {{2009, 12, 19, 2, 0, 0.},
>> 2, -21.5065}, {{2009, 12, 19, 3, 0, 0.},
>> 3, -32.7286}, {{2009, 12, 19, 4, 0, 0.},
>> 4, -44.0717}, {{2009, 12, 19, 5, 0, 0.},
>> 5, -55.1602}, {{2009, 12, 19, 6, 0, 0.},
>> 6, -65.1923}, {{2009, 12, 19, 7, 0, 0.},
>> 7, -71.9049}, {{2009, 12, 19, 8, 0, 0.},
>> 8, -71.1382}, {{2009, 12, 19, 9, 0, 0.},
>> 9, -63.5455}, {{2009, 12, 19, 10, 0, 0.},
>> 10, -53.2237}, {{2009, 12, 19, 11, 0, 0.},
>> 11, -42.0512}, {{2009, 12, 19, 12, 0, 0.},
>> 12, -30.7084}, {{2009, 12, 19, 13, 0, 0.},
>> 13, -19.5384}, {{2009, 12, 19, 14, 0, 0.},
>> 14, -8.807}, {{2009, 12, 19, 15, 0, 0.}, 15,
>> 1.2021}, {{2009, 12, 19, 16, 0, 0.}, 16,
>> 10.1347}, {{2009, 12, 19, 17, 0, 0.}, 17,
>> 17.5349}, {{2009, 12, 19, 18, 0, 0.}, 18,
>> 22.856}, {{2009, 12, 19, 19, 0, 0.}, 19,
>> 25.5574}, {{2009, 12, 19, 20, 0, 0.}, 20,
>> 25 12, 21, 16, 0, 0.}, 16,
>> 9.9842}, {{2009, 12, 21, 17, 0, 0.}, 17,
>> 17.4133}, {{2009, 12, 21, 18, 0, 0.}, 18,
>> 22.773}, {{2009, 12, 21, 19, 0, 0.}, 19,
>> 25.5215}, {{2009, 12, 21, 20, 0, 0.}, 20,
>> 25.3146}, {{2009, 12, 21, 21, 0, 0.}, 21,
>> 22.1802}, {{2009, 12, 21, 22, 0, 0.}, 22,
>> 16.5023}, {{2009, 12, 21, 23, 0, 0.}, 23, 8.8331}}
>>
>>
> 



  • Prev by Date: Re: Re: simple nest
  • Next by Date: Re: Plotting date-time series in 3D how to handle date-time to plot
  • Previous by thread: Re: Re: Plotting date-time series in 3D how to handle date-time to plot
  • Next by thread: Re: Plotting date-time series in 3D how to handle date-time to plot