.. _example-scripts:

========
Examples
========

Minimizing Python functions
---------------------------

zfit minimizers can also be used to minimize normal Python functions as shown here.

.. literalinclude:: /../examples/minimize_python_func.py


Composing PDFs
--------------
.. literalinclude:: /../examples/composing_pdf.py

Custom 3D Functor
-----------------
.. literalinclude:: /../examples/custom_3d_functor.py

Custom PDF simple
-----------------
.. literalinclude:: /../examples/custom_pdf_simple.py

Custom PDF advanced
-------------------
.. literalinclude:: /../examples/custom_pdf_advanced.py

Custom 3D PDF
-------------
.. literalinclude:: /../examples/custom_3d_pdf_simple.py

Multidimensional preprocess fit
-------------------------------
.. literalinclude:: /../examples/multidim_preprocess_fit.py

Plot signal background
----------------------
.. literalinclude:: /../examples/plot_sig_bkg.py

Simple fit
----------
.. literalinclude:: /../examples/simple_fit.py

Signal-background-mass fit
--------------------------
.. literalinclude:: /../examples/signal_bkg_mass_fit.py

Signal-background-mass fit extended
-----------------------------------
.. literalinclude:: /../examples/signal_bkg_mass_extended_fit.py

Simultanous fit
---------------
.. literalinclude:: /../examples/simultaneous_fit.py


.. _spaces-example:

Spaces
------
.. literalinclude:: /../examples/spaces.py
