Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
0
votes
0
answers
17
views
Cubic spline with circular predictor [duplicate]
$x_i$ takes values of angles, so it is a circular variable. Is there some method to perform cubic splines or some interpolation on the values of $y_i$, taking into account the circularity of $x_i$? …
8
votes
1
answer
1k
views
Modeling a spline over time -- design matrix and survey of approaches
(Modeled in ggplot using a gam specifying a "cc" circular cubic smoother). … I would like to model the (nonlinear) change in each predictor as a function of time using something like a two-dimensional spline. …
14
votes
Fitting sine wave with lm in R for circadian activity- frequencies?
Here is a Generalized Additive Model (GAM) fit using a circular spline with three knots (that is, comparable in complexity to a sine wave). … I used the R package mgcv to create this fit, employing its built-in circular splines (type "cc"). …
2
votes
I have zero inflated data, with discrete variables. Is it possible to use zero inflated pois...
As my other answer is already long, I'll use the actual data linked in a comment to illustrate circular splines for handling hourly data and further analysis of the time by treatment interaction. … Several packages help here:
library(tidyr) # formatting data
library(nnet) # multinomial fit
library(pbs) # for circular spline
library(aod) # for Wald test
library(emmeans)
library(ggplot2)
Data …
3
votes
Accepted
How to include time factor in a mixed model (investigating the interaction between two facto...
.; the only difference is in the way the model is parameterized
sinusoidal variation (as in the linked question): 2 parameters, 3 var-cov parameters
circular splines - adjustable complexity
However, … If something more complex is going on (which you might detect when looking at residual plots), you could use a quadratic model or a regression spline. …
9
votes
Accepted
What are ways to deal with circular covariates (e.g. with a GAM)?
be to use the built-in spline basis functions with periodic boundary conditions ! … bs="cp" gives a cyclic version of a P-spline …
2
votes
Integer predictors in Poisson regression
A worked example can be found here: circular periodic time series or fit with periodic splines …
0
votes
Accepted
I performed a multinomial model with bootstraping to predict the probability of the cows per...
The model, fit as a continuous function of time with a circular spline, will be evaluated at each hourly value. That's how the data were collected. …
1
vote
use GAMM models for full circular wind direction data
There is nothing per se wrong or flawed about representing wind direction, a circular variable, via a cyclic cubic regression spline. … If you have data covering the interval 20-270 degrees, the spline will be constrained to make 20 == 270, thus introducing a bias. …
20
votes
How to figure out the behind concept of statistical-look problems?
After I explained them about model building, model checking, spline bases, circular splines, penalty versus no penalty, confounding and a bit more, they understood that even a 2-day course by a trained …
17
votes
Accepted
How are piecewise cubic spline bases constructed?
Here is a piecewise constant spline with two knots. It is determined by its three levels or, equivalently, by a "baseline" level and two jumps. … For instance, I recently had to develop circular quadratic splines for a regression that involved an angular independent variable (an orientation in the plane modulo $180$ degrees). …
1
vote
Decorrelating two image maps
One method that might be effective is to create a smoothing spline model with a radial kernel that takes the coordinates of the pixel relative to the center and the thicknesses of the films as arguments … I'm assuming the images are essentially circular around some origin that you can calculate image-wise. …
2
votes
Accepted
Nested ANOVA: Correct use for colinearity problem?
(If the locations go fully around the circumference of the circle you could use circular statistics to deal with the wrap-around problem at an angle of 0/360 degrees.) …
0
votes
Cox PH Tenure Handling
You should model that predictor flexibly, for example as a cubic spline, to capture any non-linearity in the relationship. … You can quickly get into circular reasoning, so make sure that your modeling doesn't fall into that trap. …
1
vote
Cox regression model - testing the proportionality assumption for an interaction term?
So using stop time in the regression is essentially using the outcome to help predict the outcome, which is circular reasoning. …