Non-Symmetric Models: Skew-Normal, Skew-t, and NCST Families
Source:vignettes/non_symmetric_models.Rmd
non_symmetric_models.RmdMotivation
Symmetric Gaussian models assume that a species responds equally to deviations above and below its environmental optimum. Many species violate this assumption: heat tolerance may extend further than cold tolerance, or precipitation responses may be right-skewed.
xnicher provides three non-symmetric likelihood families
that relax the symmetry assumption while retaining the ellipsoidal
geometry:
| Family | Parameters | Tail weight | Background correction |
|---|---|---|---|
skew_normal |
Gaussian | No | |
skew_t |
Heavy | No | |
ncst |
Heavy | No | |
skew_normal_weighted |
Gaussian | Yes (KDE) | |
skew_t_weighted |
Heavy | Yes (KDE) | |
ncst_weighted |
Heavy | Yes (KDE) |
1 The skew-normal family
The skew-normal distribution (Azzalini and Capitanio 1999) adds a vector of skewness parameters to the multivariate normal. When , the model reduces to the symmetric Gaussian.
Fitting
library(xnicher)
set.seed(42)
fit_sn <- optimize_niche(
env_occ = example_env_occ_2d,
env_m = NULL,
likelihood = "skew_normal",
num_starts = 5L,
breadth = 0.1,
control = list(maxeval = 1000L),
verbose = FALSE
)
fit_sn
#> -- xnicher optimization result --
#> Likelihood : skew_normal
#> Starts : 5 (converged: 5 )
#> Best loglik: -668.1408
#> Convergence: 1
#> eta : 1
#> Variables : bio1WH, bio12WHThe estimated skewness parameters indicate the direction and magnitude of asymmetry:
2 The skew-t family
The skew-t model (Branco and Dey 2001) extends the skew-normal by replacing Gaussian tails with Student- tails controlled by a degrees-of-freedom parameter :
As , the skew-t converges to the skew-normal.
Fitting
set.seed(42)
fit_st <- optimize_niche(
env_occ = example_env_occ_2d,
env_m = NULL,
likelihood = "skew_t",
num_starts = 5L,
breadth = 0.1,
control = list(maxeval = 1000L),
verbose = FALSE
)
fit_st
#> -- xnicher optimization result --
#> Likelihood : skew_t
#> Starts : 5 (converged: 5 )
#> Best loglik: -718.787
#> Convergence: 1
#> eta : 1
#> Variables : bio1WH, bio12WHThe estimated degrees of freedom:
3 The NCST family
The Non-Central Skew- (NCST) places the location parameter inside the skew-normal component before chi-squared scaling:
This allows degrees of freedom to interact with the location-scale structure, providing extra flexibility compared to the standard skew-t.
Fitting
set.seed(42)
fit_ncst <- optimize_niche(
env_occ = example_env_occ_2d,
env_m = NULL,
likelihood = "ncst",
num_starts = 5L,
breadth = 0.1,
control = list(maxeval = 1000L),
verbose = FALSE
)
fit_ncst
#> -- xnicher optimization result --
#> Likelihood : ncst
#> Starts : 5 (converged: 5 )
#> Best loglik: -719.3935
#> Convergence: 1
#> eta : 1
#> Variables : bio1WH, bio12WH4 Model comparison
Compare all non-symmetric families using AIC and BIC:
cmp <- compare_xnicher(
skew_normal = fit_sn,
skew_t = fit_st,
ncst = fit_ncst
)
print(cmp[, c("model", "likelihood", "AIC", "dAIC", "BIC", "dBIC")])
#> model likelihood AIC dAIC BIC dBIC
#> 1 skew_normal skew_normal 1348.135 0.0000 1364.168 0.0000
#> 2 skew_t skew_t 1451.464 103.3291 1469.788 105.6195
#> 3 ncst ncst 1453.603 105.4687 1471.927 107.75925 Weighted variants
Each non-symmetric family has a weighted counterpart that corrects
for sampling bias using a KDE of the background environment. Supply
env_m and use the _weighted suffix:
set.seed(42)
fit_snw <- optimize_niche(
env_occ = example_env_occ_2d,
env_m = example_env_m_2d,
likelihood = "skew_normal_weighted",
num_starts = 5L,
breadth = 0.1,
control = list(maxeval = 500L),
verbose = FALSE
)
fit_snw
#> -- xnicher optimization result --
#> Likelihood : skew_normal_weighted
#> Starts : 6 (converged: 6 )
#> Best loglik: -652.4987
#> Convergence: 1
#> eta : 1
#> Variables : bio1WH, bio12WH6 When to use non-symmetric models
- Skew-normal: When the species has clearly asymmetric environmental tolerances but Gaussian-like tails.
- Skew-t: When the species tolerates extreme environmental values more than a Gaussian would predict (heavy tails).
- NCST: When additional flexibility in how tail heaviness interacts with location is needed. Compare with skew-t via AIC/BIC.
- Weighted variants: When sampling bias in the background environment must be corrected simultaneously with asymmetry.
Use compare_xnicher() or cv_xnicher() to
select among families for a given dataset.