Jump to content

Fiona Guinee

Seeq Team
  • Posts

    5
  • Joined

  • Last visited

  • Days Won

    2

Posts posted by Fiona Guinee

  1. Hello Tayyab,

    Sorry that you are experiencing this issue. Regarding your first point, there could be a number of reasons for this error and I think the most efficient way to troubleshoot would be for you to join an office hours appointment. Is there a time that is convenient for you?

    About your second point, I will raise this as a feature request on your behalf.

  2. Hello,

    Thank you for your question!

    To have the latest data at the top of the table you can make use of the sorting functionality.

    First, add the start time of the capsule as a column;

    image.png.450f8aaefb8ea823f0882563eb05ac41.png

    Then, click the three dots icon on the start column, and you will be able to sort by descending.

    image.png.3fd3cb75f8d579e1cc8530ff790f866b.png

    If the table looks too busy then you can modify the header by using the 'Headers' icon and displaying 'None' or a 'Capsule Property', for example.

    Please let me know if that helps or if you have any further questions.

  3. Hello Kemi,

    Thank you for your question. This chart can be created as follows;

    1. Calculate the moving range in the formula tool;

    abs($signal.runningDelta())

    2. Create the monthly condition using Identify > Periodic Condition tool and select a monthly duration.

    3. Use Quantify > Signal from Condition tool to find the average moving range over each month. This is “CL” as shown in the video.

    image.png.b8dfeac0e8f455cabf8124c38a01b760.png

    4. In the formula tool, calculate the UCL parameter as follows

    3.268*$average_movingrange

    Alternatively, create a new Signal from Condition to calculate the standard deviation of the moving average, and in formula use the following;

    3*$stddev_movingrange

    5. Add the signals to one lane and align their y-axis.

    image.thumb.png.8f26ee273c63b4fd194647f81e8b5730.png

    We also have a very comprehensive blog post on creating a Control Chart and applying SPC run rules which may be of interest to you.

     

    • Thanks 1
  4. Capsule Based Back Prediction or Back-Casting

    Scenario: Instead of forecasting data into the future, there may be a need to extrapolate a signal back in time based on data from an event or period of interest. The following steps will allow you to backcast a target signal from every capsule within a condition.

    Data

    Target Signal – a signal that you would like to backcast.

    Event – a condition that encapsulates the event or period of interest from which you would like to backcast the target signal. The target signal must have sufficient sample points within each capsule to create an accurate regression model.

    Method

    Step 1. Create a new extended event that will combine the capsules from the original event with a prediction window for backcasting. In this example, the prediction window is 1 hr and a maximum capsule duration of 40h is defined.

    $prediction_window = $event.beforeStart(1h)
    $prediction_window.join($event, 40h)

    Step 2. Create a new time since signal that quantifies the time since the beginning of each capsule in the extended event condition. This new signal will be the independent variable in the regression model.

    $extended_event.timeSince(1min)

    Replace 1min with a sample frequency sufficient for your use case.

    image.thumb.png.45bf0bb4bc130ee93d2f4173d75acf86.png

    Step 3. In formula, use the example below to create a regression model for the target signal, with data from the event as training data, and the time since signal as an independent variable. Assign the regression model coefficients as capsule properties for a new condition called regression condition.

    $event.transform($cap->
    {$model=$target_signal.validValues().regressionModelOLS( group($cap),false,$time_since,$time_since^2)
    $cap
    .setProperty('m1',$model.get('coefficient1'))
    .setProperty('m2',$model.get('coefficient2'))
    .setProperty('c',$model.get('intercept'))})

    The formula above creates a second-order polynomial ordinary least squares regression model. The order of the polynomial can be modified (from linear up to 9th) by adding sequential 'timesince^n' statements on line 2 and defining all coefficients as is on lines 4 and 5. See the example below of how to adjust the formula for a third-order polynomial model.

    image.thumb.png.3e6172e7cc099d52a70a8e21bf8743f6.png

    Step 4. Using the regression model coefficients from the regression condition, and the time since signal, the target signal can then be backcast over the prediction window. 

    $c = $regression_condition.toSignal('c',durationKey()).aggregate(average(),$extended_event,durationKey())   
    $m1 = $regression_condition.toSignal('m1',durationKey()).aggregate(average(),$extended_event,durationKey())    
    $m2 = $regression_condition.toSignal('m2',durationKey()).aggregate(average(),$extended_event,durationKey())    
    
    return $m1*$time_since+$m2*$time_since^2 + $c

    The example above is for a second-order polynomial and the formula needs to be modified depending on the order of the polynomial defined in Step 3. See the example below for a linear model. Note that it may be required to manually set the units (using setunits() function) of each part of the polynomial equation.

    image.thumb.png.d6726cd017cabc553cab8e0b623c4f5c.png

    Result

    The result is a new signal which backcasts the target signal for the duration of the prediction window prior to the event or period of interest. 

    image.thumb.png.fcffb7a6a6954c58a161626cd9e9b91e.png

    • Like 2
×
×
  • Create New...