Jump to content
  • To Search the Seeq Knowledgebase:

    button_seeq-knowledgebase.png.ec0acc75c6f5b14c9e2e09a6e4fc8d12.png.4643472239090d47c54cbcd358bd485f.png

Search the Community

Showing results for tags 'regression model'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Community Technical Forums
    • Tips & Tricks
    • General Seeq Discussions
    • Seeq Data Lab
    • Seeq Developer Club
    • Seeq Admin Forum
    • Feature Requests

Calendars

  • Community Calendar

Categories

  • Seeq FAQs
  • Online Manual
    • General Information

Categories

  • Published
  • Code
  • Media

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Company


Title


Level of Seeq User

Found 3 results

  1. 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. 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. 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. 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.
  2. Another common question through the support portal this morning that is of general interest To help with this example I am going to create a quick polynomial prediction using Data from Area C in the example set. Our target is going to be to try to predict compressor power as a function of all of the input weather signals If you wanted to re-create this prediction model in excel or another tool you need the coefficients from block #1 in the screenshot above and the y-intercept from block #2 in the screenshot. Inside of the workbench tool you will see rounded values for each of the coefficients and intercepts but the full values are available when you copy them to the clipboard by clicking the little button highlighted in red. To fill out the example in excel the formula will look like the following $temperature^2 * -0.000230 + $temperature * 0.0607 + $WB^2 * 0.000646 + $WB * -0.101 + 6.5946 A final point to mention here is that for multi-variable regressions with many input signals it is important to take a minute and evaluate the p-values listed in the coefficient table. If the p-values for any coefficient are above 0.05 it is best practices to rethink if that signal needs to be included in the model at all or if you may need to perform data data cleansing or re-alignment to create a better performing model. Good blog post on P-values - https://medium.com/analytics-vidhya/understanding-the-p-value-in-regression-1fc2cd2568af Great reference post on how to optimize regression models using time shifting -
  3. Hi All, I'm working on some data , wherein i have 6 Independent variable and 1 dependent variable. while running the Regression model on this data, i get very less Accuracy of model as mentioned in below screenshot. Note :- As far as data Pre-processing is concern , i have scale the features and also imputes the missing values on the basis of mean imputation. Do let me know if there's any pre-processing feature is there in seek to deal with data. Regards, JItesh Vachheta
×
×
  • Create New...