MathGroup Archive 2008

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

Search the Archive

Re: Graph by Date

I believe that the date format needs to be in quotes;  so your data
will have to look as the following:

mydata = {{"1/5/2004", "widgetA", 55.2}, {"1/15/2004", "widgetD32",
   5.2}, {"2/7/2004", "no_Widgets", 34.5}, {"5/6/2004", "widget62",
   100.2}, {"5/16/2004", "widget6", 30.5}, {"9/13/2004", "widget 55t",

Then you can use the following command to only take the date and the

cs = Drop[mydata[[Range[Length[mydata]], {1, 3}]]]

You can then use your plotting routine - I changed the PlotRange for
the Y-axis so that you can see the filling from 0 to the value of

DateListPlot[cs, Filling -> Bottom, FillingStyle -> Blue,
 PlotStyle -> {Red, PointSize[Large]},
 PlotRange -> {{{2004, 1}, {2004, 12}}, {0, 250}},
 DateTicksFormat -> {"Month", "/", "YearShort"}]

I am sure there is a simpler and more efficient manner to accomplish
the same task - I hope this does the job for now.

Good Luck.

  • Prev by Date: Re: newbie question
  • Next by Date: Re: best book to quickly master all Mathematica functions, and commands
  • Previous by thread: Re: Graph by Date
  • Next by thread: Re: Graph by Date