Skip to content

gitRasheed/pyNNS

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

162 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PyNNS

Python port of the R NNS 12.1 beta package.

  • PyPI package: nns-pm
  • Import name: pynns
  • Runtime dependencies: NumPy, SciPy
  • R required for normal use: no
  • Status: alpha, parity-focused
  • License: GPL-3.0-only

Install

pip install nns-pm

Quick Use

import numpy as np
from pynns import lpm, nns_dep, nns_reg

x = np.array([-2.0, -1.0, 0.5, 3.0])
downside = lpm(2, 0.0, x)

grid = np.linspace(-2.0, 2.0, 50)
dep = nns_dep(grid, grid**2)

fit = nns_reg(grid, np.sin(grid), point_est=np.array([-1.0, 0.0, 1.0]))

Documentation

Development

uv sync --group dev
uv run pytest
uv run ruff check .
uv run mypy

R and the R NNS package are only needed to regenerate parity fixtures.

Attribution

NNS was created by Fred Viole as the companion R package to Viole, F. and Nawrocki, D. (2013), Nonlinear Nonparametric Statistics: Using Partial Moments.

Upstream: OVVO-Financial/NNS

About

Python port of Nonlinear Nonparametric Statistics R Library

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors