Giter Site home page Giter Site logo

kyrylo-gr / ffit Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 1.0 3.94 MB

Make curve fitting as easy as possible

Home Page: https://kyrylo-gr.github.io/ffit/

License: GNU Lesser General Public License v3.0

Python 4.90% Jupyter Notebook 95.10%
curve-fitting data-analysis data-visualization fitting

ffit's Introduction

FFit. Fit python library.


Pypi Python 3.7+ License Code style: black CodeFactor Codecov Download Stats Documentation

FFit - Python library for easier fitting.

Install

pip install ffit

For more installation details, please refer to the How to install

How to use

The aim of this library is to simplify the fit routine. Here are some examples of how to use it.

Simple syntax

import ffit as ff

x = np.linspace(1, 10, 100)
y = 2 * np.sin(x) + 3

res = ff.Cos.fit(x, y).res

Plotting result

import ffit as ff
import matplotlib.pyplot as plt

x = np.linspace(1, 10, 100)
y = 2 * np.sin(x) + 3

plt.plot(x, y, '.')

res = ff.Cos.fit(x, y).plot().res

Plotting guess

The quality of fitting is heavily dependent on the initial guess. This library provides initial guesses for various popular functions to ensure effectiveness. However, if something goes awry, you can verify the guess and set it manually.

ff.Cos.guess(x, y).plot()

ff.Cos.guess(x, y, guess=[1,2,3,4]).plot()

ff.Cos.fit(x, y, guess=[1,2,3,4]).plot()

Other functions

Numerous functions are available out of the box. You can refer to the documentation for more details.

Moreover, you can use your custom functions with familiar syntax and still benefit from existing routines.

ffit's People

Contributors

kyrylo-gr avatar lkb-omq avatar

Watchers

 avatar

Forkers

lkb-omq

ffit's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.