Package: sdetorus 0.1.10

Eduardo García-Portugués

sdetorus: Statistical Tools for Toroidal Diffusions

Implementation of statistical methods for the estimation of toroidal diffusions. Several diffusive models are provided, most of them belonging to the Langevin family of diffusions on the torus. Specifically, the wrapped normal and von Mises processes are included, which can be seen as toroidal analogues of the Ornstein-Uhlenbeck diffusion. A collection of methods for approximate maximum likelihood estimation, organized in four blocks, is given: (i) based on the exact transition probability density, obtained as the numerical solution to the Fokker-Plank equation; (ii) based on wrapped pseudo-likelihoods; (iii) based on specific analytic approximations by wrapped processes; (iv) based on maximum likelihood of the stationary densities. The package allows the replicability of the results in García-Portugués et al. (2019) <doi:10.1007/s11222-017-9790-2>.

Authors:Eduardo García-Portugués [aut, cre]

sdetorus_0.1.10.tar.gz
sdetorus_0.1.10.tar.gz(r-4.5-noble)sdetorus_0.1.10.tar.gz(r-4.4-noble)
sdetorus_0.1.10.tgz(r-4.4-emscripten)sdetorus_0.1.10.tgz(r-4.3-emscripten)
sdetorus.pdf |sdetorus.html
sdetorus/json (API)
NEWS

# Install 'sdetorus' in R:
install.packages('sdetorus', repos = c('https://cran.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

Bug tracker:https://github.com/egarpor/sdetorus/issues

Uses libs:
  • openblas– Optimized BLAS
  • c++– GNU Standard C++ Library v3

1.48 score 1 packages 9 scripts 218 downloads 93 exports 3 dependencies

Last updated 9 months agofrom:e14dc98b3e. Checks:OK: 2. Indexed: no.

TargetResultDate
Doc / VignettesOKOct 30 2024
R-4.5-linux-x86_64OKOct 30 2024

Exports:a1InvalphaToAapproxMleWn1DapproxMleWn2DapproxMleWnPairsaToAlphaconstBvmconstJpcovstOucovtMoucrankNicolson1DcrankNicolson2DdBvmdiffCircdJpdPsTpddriftJpdriftMixIndVmdriftMixVmdriftMvmdriftWndriftWn1DdriftWn2DdStatWn2DdTpdMoudTpdOudTpdPde1DdTpdPde2DdTpdWoudTpdWou1DdTpdWou2DdVmdWn1Deuler1Deuler2DforwardSweepPeriodicTridiagforwardSweepTridiagijIndexintegrateSimp1DintegrateSimp2DintegrateSimp3DkColToRowkIndexkRowToCollinesCirclinesToruslinesTorus3dlogBesselI0ScaledlogLikWouPairsmatlab.like.colorRampsmatMatchmcTorusIntegratemeantMoumeantOumleMoumleOptimWrappermleOumlePde1DmlePde2DmomentMatchWnVmperiodicTrapRule1DperiodicTrapRule2DperiodicTrapRule3DplotSurface2DplotSurface3DpsMlerepColrepRowrStatWn2DrTpdWn2DrTrajLangevinrTrajMourTrajOurTrajWn1DrTrajWn2DsafeSoftMaxscoreMatchWnBvmscoreMatchWnVmsigmaDiffsolvePeriodicTridiagsolveTridiagsolveTridiagMatConstsstepAheadWn1DstepAheadWn2Dto2PiInttoInttoPiInttorusAxistorusAxis3dunwrapCircSeriesvartOuweightsLinearInterp1DweightsLinearInterp2D

Dependencies:mvtnormRcppRcppArmadillo

Readme and manuals

Help Manual

Help pageTopics
Valid drift matrices for the Ornstein-Uhlenbeck diffusion in 2DalphaToA aToAlpha
Approximate MLE of the WN diffusion in 1DapproxMleWn1D
Approximate MLE of the WN diffusion in 2DapproxMleWn2D
Approximate MLE of the WN diffusion in 2D from a sample of initial and final pairs of angles.approxMleWnPairs
Crank-Nicolson finite difference scheme for the 1D Fokker-Planck equation with periodic boundariescrankNicolson1D
Crank-Nicolson finite difference scheme for the 2D Fokker-Planck equation with periodic boundariescrankNicolson2D
Bivariate Sine von Mises densityconstBvm dBvm
Lagged differences for circular time seriesdiffCirc
Jones and Pewsey (2005)'s circular distributionconstJp dJp
Wrapped Euler and Shoji-Ozaki pseudo-transition probability densitiesdPsTpd
Drift for the JP diffusiondriftJp
Drift for the mivM diffusiondriftMixIndVm
Drift for the mivM diffusion (circular case)driftMixVm
Drift for the MvM diffusiondriftMvm
Drift for the WN diffusiondriftWn
Drift of the WN diffusion in 1DdriftWn1D
Drift of the WN diffusion in 2DdriftWn2D
Stationary density of a WN diffusion (with diagonal diffusion matrix) in 2DdStatWn2D
Transition probability density of the multivariate OU diffusioncovtMou dTpdMou meantMou
Transition probability density of the univariate OU diffusioncovstOu dTpdOu meantOu vartOu
Transition probability density in 1D by PDE solvingdTpdPde1D
Transition probability density in 2D by PDE solvingdTpdPde2D
Conditional probability density of the WOU processdTpdWou
Approximation of the transition probability density of the WN diffusion in 1DdTpdWou1D
Approximation of the transition probability density of the WN diffusion in 2DdTpdWou2D
Density of the von MisesdVm
WN density in 1DdWn1D
Simulation of trajectories of the WN or vM diffusion in 1Deuler1D
Simulation of trajectories of the WN or MvM diffusion in 2Deuler2D
Lines and arrows with vertical wrappinglinesCirc
Lines and arrows with wrapping in the toruslinesTorus
Lines and arrows with wrapping in the toruslinesTorus3d
Efficient computation of Bessel related functionsa1Inv logBesselI0Scaled
Loglikelihood of WN in 2D when only the initial and final points are observedlogLikWouPairs
Maximum likelihood estimation of the multivariate OU diffusionmleMou
Optimization wrapper for likelihood-based proceduresmleOptimWrapper
Maximum likelihood estimation of the OU diffusionmleOu
MLE for toroidal process via PDE solving in 1DmlePde1D
MLE for toroidal process via PDE solving in 2DmlePde2D
Quadrature rules in 1D, 2D and 3DintegrateSimp1D integrateSimp2D integrateSimp3D periodicTrapRule1D periodicTrapRule2D periodicTrapRule3D
Maximum pseudo-likelihood estimation by wrapped pseudo-likelihoodspsMle
Simulation from the stationary density of a WN diffusion in 2DrStatWn2D
Simulation from the approximated transition distribution of a WN diffusion in 2DrTpdWn2D
Simulation of trajectories of a Langevin diffusionrTrajLangevin
Simulation of trajectories for the multivariate OU diffusionrTrajMou
Simulation of trajectories for the univariate OU diffusionrTrajOu
Simulation of trajectories for the WN diffusion in 1DrTrajWn1D
Simulation of trajectories for the WN diffusion in 2DrTrajWn2D
Safe softmax function for computing weightssafeSoftMax
Score and moment matching of a univariate or bivariate wrapped normal by a von MisesmomentMatchWnVm scoreMatchWnBvm scoreMatchWnVm
sdetorus - Statistical Tools for Toroidal Diffusionssdetorus-package sdetorus
High-frequency estimate of the diffusion matrixsigmaDiff
Thomas algorithm for solving tridiagonal matrix systems, with optional presaving of LU decompositionforwardSweepPeriodicTridiag forwardSweepTridiag solvePeriodicTridiag solveTridiag solveTridiagMatConsts
Multiple simulation of trajectory ends of the WN or vM diffusion in 1DstepAheadWn1D
Multiple simulation of trajectory ends of the WN or MvM diffusion in 2DstepAheadWn2D
Wrapping of radians to its principal valuesto2PiInt toInt toPiInt
Draws pretty axis labels for circular variablestorusAxis
Draws pretty axis labels for circular variablestorusAxis3d
Unwrapping of circular time seriesunwrapCircSeries