Questions tagged [periodicity]

Questions about periodicity, an interval of time. It can represent a clock or an interval between days, minutes or any other unit of time.

Questions about periodicity, an interval of time. It can represent a clock or an interval between days, minutes or any other unit of time.

83 questions
0
votes
1 answer

Call an expensive function periodically inside a loop

I call a computationally expensive function inside a loop: for( int j = 0; j < Max; ++j ) { // ... processQueuedEvents(); // Computationally expensive call // ... } However, I don't need to run the expensive function on every single…
Megidd
  • 7,089
  • 6
  • 65
  • 142
0
votes
2 answers

Periodic regression coefficient in a panel data r

I have a panel data frame like this. where return is the dependent variable and mkreturn is the independent variable. Firm date return mkreturn A Jan-07 7 12 A Feb-07 8 14 A Mar-07 2 16 A Apr-07 4 18 A May-07 2 …
Max
  • 117
  • 7
0
votes
1 answer

plotting repeated periodic solution

I am trying to plot a repeated periodic solution using matplotlib in python. I have the solution for one period, I have provided a sample test code below of the individual plot: import matplotlib import numpy as np from matplotlib import pyplot as…
Jeff Faraci
  • 403
  • 13
  • 28
0
votes
0 answers

First day of the week problem while using xts's period.apply()

I am trying to convert my daily series to weekly frequency by using xts package. However, I couldn't figure out how to dictate the first week of my series is Sunday. Documentation on function doesn't refer any arguments which can be used for this…
omzeybek
  • 305
  • 2
  • 14
0
votes
0 answers

Classifying Spikes of different periodicity among Data

I am trying to classify spikes in real Data. Mostly there are two classes of Spikes in the data, which have slightly different frequency and also different amplitude. Annoyingly the frequency of the classes is not fixed, but may vary a little bit…
0
votes
1 answer

How to plot piecewise cosine and make it periodic?

Hi I have this piecewise function and its graph :cosine and right graph I supposed to implement that piecewise in python and get the same graph at the next. My code is this : import numpy as np import matplotlib.pyplot as plt def f(time): …
kemal
  • 23
  • 7
0
votes
1 answer

periodiccallback of asynchronous function

Does PeriodicCallback ensure no parallel executions? Is the callback triggered while a previous triggered one is still running or does it ensure that there is only one callback running at a time? As far as I can see the later one is true, but I want…
0
votes
1 answer

python tornado periodicCallback at specific time

my goal is very simple: starting a periodicCallback at a specific time. I tried to look everywhere but all the examples read are related to a timedelta of the current time and not to a defined time. I write a simple example. import…
0
votes
1 answer

How to call a method / function periodically? (time.sleep fails)

How can I call update periodically? I tried the following but it skips showing GUI for the limit seconds and then shows only the last update: import tkinter as tk import time root = tk.Tk() widget = tk.Label(root, text="Initial…
Nae
  • 14,209
  • 7
  • 52
  • 79
0
votes
0 answers

Determine instantaneous phase from two shifted periodic signals with unknown offset

I have two periodic noisy signals which depend on a constantly increasing reference angle. The two signals are shifted by 90 degrees and one of them has an unknown varying offset. Two sample signals like this can be generated using a simple python…
Nickj
  • 982
  • 3
  • 8
  • 17
0
votes
1 answer

Data Periodicity - How to normalize?

I have a data set which contains 12 years of weather data. For first 10 years, the data was recorded per day. For last two years, it is now being recorded per week. I want to use this data in Python Pandas for analysis but I am little lost on how to…
Guru
  • 148
  • 1
  • 12
0
votes
1 answer

Time model for glfwSwapBuffers

This function sets the swap interval for the current context, i.e. the number of screen updates to wait before swapping the buffers of a window and returning from glfwSwapBuffers. This is sometimes called 'vertical synchronization', 'vertical…
user877329
  • 6,717
  • 8
  • 46
  • 88
0
votes
3 answers

Showing a value periodicaly in a new column, based on another column value

I would like to have a query that based on the field "Periodicity", would repeat every N rows the value True, grouped by the field "Type". I think I can explain better with an example: By having the next table... id type periodicity 1 1 3 2 …
RSilva
  • 6,753
  • 11
  • 43
  • 49
0
votes
1 answer

Netlogo create a periodic function

I would create a periodic function in Netlogo based on ticks and a price variable. I would like a function where price is maintained between 2 rang (0 and 1) and I will be great if I can choose the periodicity. my small reproducible example…
delaye
  • 1,357
  • 27
  • 45
0
votes
1 answer

Dynamically reboot server periodically using cronjob

I need my server to reboot after every 5 days of uptime if it is not rebooted and again reboot after exactly 5 days and continue this process consecutively. I would like to know how to do this with cronjob or any other script
Neo
  • 1
  • 3