Skip to content

nlsic

Non Linear Least Squares with Inequality Constraints

v1.2.0 · Jan 27, 2026 · GPL-2

Description

We solve non linear least squares problems with optional equality and/or inequality constraints. Non linear iterations are globalized with back-tracking method. Linear problems are solved by dense QR decomposition from 'LAPACK' which can limit the size of treated problems. On the other side, we avoid condition number degradation which happens in classical quadratic programming approach. Inequality constraints treatment on each non linear iteration is based on 'NNLS' method (by Lawson and Hanson). We provide an original function 'lsi_ln' for solving linear least squares problem with inequality constraints in least norm sens. Thus if Jacobian of the problem is rank deficient a solution still can be provided. However, truncation errors are probable in this case. Equality constraints are treated by using a basis of Null-space. User defined function calculating residuals must return a list having residual vector (not their squared sum) and Jacobian. If Jacobian is not in the returned list, package 'numDeriv' is used to calculated finite difference version of Jacobian. The 'NLSIC' method was fist published in Sokol et al. (2012) <doi:10.1093/bioinformatics/btr716>.

Downloads

CRAN

354

Last 30 days

11941st

896

Last 90 days

4.6K

Last year

Trend: +39.9% (30d vs prior 30d)

r2u CRAN

0

Last 30 days

25

Last 90 days

127

Last year

Trend: -100% (30d vs prior 30d)

autoCRAN

4

Last 7 days

11

Last 30 days

2

All-time

autoCRAN-only: this name is served only by autoCRAN, so the count is exact.

CRAN Check Status

13 OK
Show all 13 flavors
Flavor Status
r-devel-linux-x86_64-debian-clang OK
r-devel-linux-x86_64-debian-gcc OK
r-devel-linux-x86_64-fedora-clang OK
r-devel-linux-x86_64-fedora-gcc OK
r-devel-windows-x86_64 OK
r-oldrel-macos-arm64 OK
r-oldrel-macos-x86_64 OK
r-oldrel-windows-x86_64 OK
r-patched-linux-x86_64 OK
r-release-linux-x86_64 OK
r-release-macos-arm64 OK
r-release-macos-x86_64 OK
r-release-windows-x86_64 OK

Check History

OK 13 OK · 0 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE Jun 9, 2026
ERROR 12 OK · 0 NOTE · 0 WARNING · 1 ERROR · 0 FAILURE Jun 8, 2026
ERROR r-devel-linux-x86_64-debian-gcc

DESCRIPTION meta-information

Fatal error: cannot create 'R_TempDir'
OK 14 OK · 0 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE Mar 10, 2026

Code

Code metrics have not been computed for this package yet.

Reverse Dependencies (2)

depends

imports

Dependency Network

Dependencies Reverse dependencies nnls dotty glue dynafluxr bspline nlsic

Version History

7 tracked
new 1.2.0 Mar 10, 2026
updated 1.2.0 ← 1.1.1 diff Jan 27, 2026
updated 1.1.1 ← 1.1.0 diff Jun 26, 2025
updated 1.1.0 ← 1.0.4 diff May 15, 2025
updated 1.0.4 ← 1.0.2 diff Jun 25, 2023
updated 1.0.2 ← 1.0.1 diff Apr 11, 2022
new 1.0.1 Jan 10, 2022