Plotting - plot.py

This module defines two functions to plot the data contained in an object of class data.Dataset. The function plot_c() plots the species concentration evolution over time and the function plot_q() plots the charge passed evolution over time. If no fit was performed on the dataset object these functions only plot the raw data. If a fit was performed it also plot the fit estimation.

plot.plot_c(dataset, names=None)

Plots the species concentrations evolution over time and its fit.

Plots the fit results only if the data has been fitted once, i.e. chemical_kinetics.fit.fit_dataset function was run once on the dataset. Else it only plots the raw data.

Parameters:
  • dataset (chemical_kinetics.data.Dataset) – Object holding the DataFrame containing the data and the fit results.
  • names (list, optional) – List of names of the species concentration and fit to be plotted, if None all concentrations are plotted.
plot.plot_q(dataset)

Plots the charge passed over time and its fit.

Plots the fit results only if the data has been fitted once, i.e. chemical_kinetics.fit.fit_dataset function was run once on the dataset. Else it only plots the raw data.

Parameters:dataset (chemical_kinetics.data.Dataset) – Object holding the DataFrame containing the data and the fit results.