Bug #3203

Add dateType

Added by Derik Barseghian about 11 years ago. Updated almost 11 years ago.

Target version:
Start date:
Due date:
% Done:


Estimated time:


Add a date type to Kepler; being able to pass date tokens between a variety of actors would be nice. My original motivation was to feed them to plot and other display actors.

Here a response from Christopher Brooks Sep 24,2007 on the original dateType/plotting topic:
Hi Derik,
You could use the to encapsulate a Date.
See for an example of a Token.

In the type hierarchy, the Date type would be convertable to String,
but probably nothing would be convertable to Date.

Adding date support to Ptplot would appear to be easy, but doing a
complete job would be very difficult.

The easy part is that one can easily specify ticks that consist of
a label and value. Thus, you could specify "January 1, 1970 00:00:00"
as 0 and then specify times in seconds since then.

for an example that uses ticks.

The hard part is: given a set of arbitrary Java Dates, label the axes
nicely, where nicely is defined as:
- text does not overlap.
- text displays meaningful values.
For example, if we are just looking at 15 seconds, do we
care about the day, month and year.

The code that labels the axes has lots of art in it. That code was
written a very long time ago - before many of the layout managers were

There is also this entire question of the provenance of data. Perhaps
we would like to be able to attach metadata, such as the date, to
data points. The tricky part here would be to not make the Token
classes too large. Also, I'm not sure what you would do with the

If you have data streams that have irregular time stamps, then you
might want to look at timed domains such Discrete Event. It is
possible to use SDF and have each iteration represent a tick of the
clock, but if you have data streams that have times associated with
them, then SDF is probably not what you want.



#1 Updated by Christopher Brooks about 11 years ago

See also
"Plotter should be better about displaying times"

#2 Updated by Derik Barseghian almost 11 years ago

closing, dan crawl has checked in a DateToken and related code in kepler/date/

#3 Updated by Redmine Admin about 6 years ago

Original Bugzilla ID was 3203

Also available in: Atom PDF