Questions tagged [date-and-time]

Questions about Mathematica's date and time functions.

Filter by
Sorted by
Tagged with
1
vote
0answers
18 views

TimeSeriesRescale seems to work oddly

I have been attempting to do some date computations with EventSeries, a convenient form for storing economic quantities (like expenses) over time. Following the documentation, I created an list of ...
2
votes
1answer
18 views

Converting string date to date object and retriving time difference

I am manipulating a text file, I need to extract dates from it, that will be in the format XJan__28_,__2020X where _ is either 1 or zero whitespaces __ is 1 or more than 1 whitespaces X is a ...
0
votes
0answers
28 views

Date interpretation problem

What am I doing wrong? DateObject[{"1/31/2020 2:00 AM", {"Month", "/", "Day", "/", "Year", " ", "Hour12", ":", "Minute", " ", "AMPM"}}] DateObject::str: String ...
2
votes
1answer
120 views

Combine BarChart and TimeLinePlot

I have a Barchart like this: ...
1
vote
1answer
62 views

How to Manipulate DataObject or increment time?

I'm really new to the Mathematica, anyway my task is to write an application which would show position of ISS on the map but with manipulation/slider option to check position of ISS according to the ...
0
votes
1answer
28 views

Parsing time interval strings as “Uncertain” Time Intervals

Problem: I have strings of form "[d1, d2]" or sometimes just [d1] where d1 and ...
1
vote
0answers
31 views
2
votes
1answer
63 views

Does Mathematica has a notion of Half Year in its DateObject

I can convert any DateObject to its current quarter as follows: DateObject[Now,"Quarter"] But if I want to look at whether my ...
0
votes
0answers
33 views

DatePattern “MonthName” with foreign languages?

Is there a way to get DatePattern to work with date "MonthName"s in foreign languages? ...
2
votes
1answer
48 views

What can I do about my DateListPlot plotting incorrectly?

I have noticed that ...
8
votes
2answers
174 views

TimeLinePlot tooltip shows Day rather than Year

Update 2019-11-28 WRI has confirmed that this is a bug. Update 2019-11-25 The workaround suggested by @alx works if all of the dates have the same granularity. While experimenting with the ...
13
votes
2answers
219 views

How do you import “ISODateTime” and capture the time zone?

Bug introduced in V10.4 or earlier and persisting through 12.0 (CASE:3920785) Back in version 10.2 or so, Mathematica began supporting the ISO 8601 date/time format, which is nice because it's used ...
1
vote
1answer
46 views

Import and Export DateObject

I'm trying to import a spreadsheet with dates and export it again. But the cell reads ### in the exported file. It's shown in the screenshots. This is my code. ...
0
votes
0answers
42 views

tickless DateListPlot [duplicate]

I am using Mathematica 12.0, and when I do a DateListPlot, I get the following minimalist output: Is this some known problem, or did I not sacrifice to the appropriate gods? ADDENDUM Carl's example ...
5
votes
2answers
95 views

How can dates be formatted with Tooltip in a DateListPlot?

After creating an association of time series as follows: ...
1
vote
0answers
35 views

AbsoluteTime problem [duplicate]

This simple table command holds no mysteries: n = 10; tmin = 0; tmax = 10; dt = (tmax - tmin)/n; list = Table[t, {t, tmin, tmax, dt}] nList = Length[list] The ...
3
votes
1answer
44 views

Is there a better fix for this problem with Legended in DateListPlot?

data = {{{{2010, 3, 31}, 100.}, {{2010, 9, 30}, 110.}}, {{{2010, 3, 31}, 80.}, {{2010, 9, 30}, 90.}}}; DateListPlot[data] With only two data points in all the ...
8
votes
1answer
229 views

Is there a way to obtain the time when an input was executed in a notebook?

I have a notebook with lots of In[n] in my current session. The notebook has been open for over three days. I would like to get the timestamps for when certain old ...
0
votes
0answers
40 views

Bug in DayRange?

DayRange[DateObject[{2019, 1, 1}], DateObject[{2019, 12, 31}], "Holiday", HolidayCalendar -> "Germany"] Why is Oct 3 missing? It's German Unity Day since ...
4
votes
2answers
90 views

Manipulation and sorting of date strings, location Australia

Question 1 DateObject["30.08.90"] returns Day: Mon 2 Jun 1997. How do I get ...
4
votes
0answers
87 views

Dynamic Clock Stops Ticking

I want a dynamic timer to tell me how long it has been since a file update. I have coded a simple timer for this, but an hour or two in after completing an update, the dynamic timer stops responding ...
3
votes
0answers
75 views

Bug in LeapYearQ? [closed]

{#, LeapYearQ[DateObject @ {#, 1, 1}]} & /@ Range[-1000, 3000, 100] I'm surprised to find 0, 400, 800, 1200 with a True. I'm not aware that the leap year rule ...
2
votes
0answers
33 views

Bugs in PreviousDate and NextDate?

{PreviousDate[{2017, 1, 1, 0, 0, 0}, "Second"], NextDate[{2016, 12, 31, 23, 59, 59}, "Second"]} 2016 had an extra leap second. The last second of 2016 was not ...
3
votes
1answer
94 views

Daylight hours vs calendar date

Is there a way in Mathematica or Wolfram Alpha to get a plot of daylight hours vs calendar date and rate of change of daylight hours vs calendar date. Lets say I want the plot for latitude 45 degrees ...
3
votes
3answers
73 views

DateListPlot shaded area between Gridlines

I have been trying to figure out how to shade between Gridlines and I couldn't on my own, but found this post that almost has the perfect response except that the spaces between the frame and the ...
1
vote
1answer
43 views

Convert a dateobject to list

Im trying to extract a list of times from a list of Dates from the Sunrise function ...
8
votes
1answer
101 views

DateObject granularity conversion

Is there a way to convert the DateObject whose FullForm is: ...
3
votes
1answer
146 views

How to plot the hour of the sunsets

i have this code: ...
3
votes
0answers
38 views

StarData, Altitude/Azimuth Anomaly with TimeZones

I am trying to compute lunar parallax using the position of the star Regulus on February 19th of this year. I get different answers depending on how I specify the date. Here are the particulars: <...
4
votes
1answer
37 views

Permanently labeling events on a stock DateListPlot, perhaps using ToolTip?

I would like to add notes to specific days on a DateListPlot of a stock price, and have them always be visible (not just on mouseover). So far I've got how to add a tooltip to a specific day, but not ...
4
votes
3answers
117 views

Adding and Multiplying Elements of a list together

I am trying to manipulate a file to change the time into UnixTime and for that I need the date and time but of course it needs to be date first and time second. I've tried multiplying and I've tried ...
0
votes
0answers
35 views

How to include `TimeConstraint` in `EulerEquations`? Is there any error here?

There is a complicated statement which takes a long time to compute. IS THERE ANY ERROR IN THE ATTACHED PICTURE? If YES, how can I include TimeConstraint of ...
0
votes
0answers
28 views

DateListPlot or combine two different lists of values for two different dates in just one day

I have created a graph with a daily load diagram which takes data from certain period of year and compare mean values in peak time (11:00 to 16:00) and displays this day with highest mean values (it ...
6
votes
2answers
147 views

Collect data points in a list into weekly groups?

Consider data of a format such as ...
1
vote
1answer
60 views

Suppressing DateString default behavior when parts of date are missing

By subsampling data from a Excel spreadsheet I have created a Mathematica dataset that I then seek to modify by applying various functions to the fields to convert these data into a different flat ...
1
vote
1answer
38 views

How to set a time range for one day and transpose it with a certain number

I would like to create a time list for one day with range from 0:00 to 23:50 and transpose this list with a constant number 239 and then transpose these two lists. I tried to make it but it doesn't ...
2
votes
1answer
47 views

Compare values in specific times between several days

I have imported csv file which is a Daily Load Diagram consisting of 3 months (1st dec 2018 to 28th feb 2019) and the values of current are taken every 10 seconds. ...
9
votes
1answer
143 views

Does Mathematica have a date region function together with operations like intersection?

Consider the following scenario. Suppose I consider time range from TimeObject[{18,30,0}] to TimeObject[{22,30,0}] on Weekdays ...
0
votes
1answer
74 views

Import many csvs from folder and change date format from american to european

I have many csv files in one folder and I have to import all of them into Mathematica. I need actually just two columns and all the rows except for the first one so I got rid of another 6 columns and ...
8
votes
1answer
156 views

Datasets and Time Values: Filtering and Plotting

After struggling for a few weeks, I have accumulated a few examples of challenging date-related operatations with datasets. Some I have partial solutions; others I cannot yet do. The resources on ...
7
votes
2answers
242 views

How to convert dayname to number?

When I input DayName[{2012,12,24}] I get Monday as output. What is the most effective way to convert Monday into 1, Tuesday into ...
7
votes
1answer
145 views

Show timing of every output

I know I can follow Wolfram's guide and enable "ShowTiming" to show the timing of the previous command at the bottom of the window. Additionally, I can enable <...
1
vote
1answer
45 views

Applying Function to Ambiguous Dates in a Dataset

I have a large Dataset with a few columns that contain ambiguous date strings in a variety of formats. I am wanting to reformat these so they are all the same. ...
1
vote
1answer
32 views

Plotting a Histogram3D with time (a file per frame) as parameter?

I've been working for a few days trying to make a dynamic histogram on Mathematica, but I can't seem to make it happen. You see, I'm fairly new to working with Mathematica and thus lack some knowledge ...
1
vote
0answers
49 views

Prospective StartOfTime and EndOfTime in Mathematica

When working with conditions for numbers we have a notion of \[Infinity] representing larger than any other number and similarly ...
4
votes
1answer
85 views

Converting Daily Time Series Data into Low Frequency Data (Weekly, Bi-weekly, Monthly,..)

I have daily time series example data as follows: ...
4
votes
0answers
64 views

Built-in function (or terse method) to convert from DateObject to Python datetime in Python?

When using the Wolfram Client Library for Python in a Python program there appears to be no built-in function to convert a DateObject in to a Python ...
0
votes
0answers
33 views

DateListPlot show point with a thin bar

I have a list of date points and I want to show each point with a single verticle line that connects the point with the x-axis. I imagine that the solution should be the same as for a ListPlot.
0
votes
0answers
29 views

DateList returns unexpected result

Why does DateList[{"2018W01", {"Year", "W", "Week"}}] return this {2018, 12, 31, 0, 0, 0.} By the way, it works in ...
1
vote
1answer
38 views

DateListPlot Didn't Display the Data [closed]

I'm trying to plot the data with DateListPlot function, but having some issues with the output. Here is what I'm doing. I'm downloading and parsing RAW JSON like this and extracting values section ...

1 2 3 4 5 8