MathGroup Archive 2007

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

Search the Archive

Re: why DateListPlot is so slow?


Arkadiusz.Majka at gmail.com wrote:
> Hi,
> 
> I have a list (a time series):
> 
> data={{00:00:30,x1},{00:01:00,x2},{00:01:30,x3},....}
> 
> at equally spaced time intervals (30 seconds). The length od data is
> 8100 (24 h)
> 
> DateListPlot[data] works fine but takes 28 sec, since
> ListPlot[data[[All,2]]] does it in less than 0.1 sec....
> 
> Can you explain me why DateListPlot is so time consuming? Can we
> improve it?

As written, data is an invalid Mathematica expression:

In[3]:= data = {{00 : 00 : 30, x1}, {00 : 01 : 00, x2}, {00 : 01 : 30,
     x3}}

During evaluation of In[3]:= Syntax::sntxf: "{" cannot be followed by \
"00:00:30,x1}".

During evaluation of In[3]:= Syntax::tsntxi: "00:00:30" is \
incomplete; more input is needed.

During evaluation of In[3]:= Syntax::sntxi: Incomplete expression; \
more input is needed.

Using strings does not solve the issue either

In[1]:= data = {{"00:00:30", x1}, {"00:01:00", x2}, {"00:01:30", x3}}

Out[1]= {{"00:00:30", x1}, {"00:01:00", x2}, {"00:01:30", x3}}

In[2]:= DateListPlot[data]

During evaluation of In[2]:= DateListPlot::ntdt: The first argument \
to DateListPlot is not a list of pairs of dates and real values or a \
list of lists of pairs of dates and real values. >>

Out[2]= DateListPlot[{{"00:00:30", x1}, {"00:01:00", x2}, {"00:01:30",
     x3}}]

So the question is, "Could you please post an example of the _real_ 
structure of the dataset you feed to *DateListPlot*?"

-- 
Jean-Marc


  • Prev by Date: Re: Re: How show Locator point and its image under a function?
  • Next by Date: Re: why DateListPlot is so slow?
  • Previous by thread: Re: why DateListPlot is so slow?
  • Next by thread: Re: why DateListPlot is so slow?