Package: lpplotlib
lpplotA user-friendy wrapper formatplotlib.pyplotlinear plots.Table of contentsIntroductionInstallationUsageTutorialDonationsLicenseIntroductionCustomizingmatplotlibplots is not always intuitive. Changing grids, labels, pads, etc. often needs searching internet for a time, and probably you will need to repeat these searches after a while.lpplotlib.pyplotis a small project that intends this customization to be simple, and repetitive.For now, onlyline2dplots are covered (i.e. plots using the famousmatplotlib.pyplot.plotcommand). Yet you may find that even at this levellpplotlib.pyplotcan be very helpful!.InstallationUse the package managerpipto install,pipinstalllpplotUsagelpplotlib.pyplotis intended to be used in a notebook enviroment, although you can also use the package in any python script. The required imports areimportmatplotlib.pyplotaspltimportlpplotlib.pyplotaslppA main feature inlpplotlib.pyplotis to collect all plot parameters in an object of the classplot_parameters. Parameters are defined through akey, using the methodplot_parameters.set(key, value). Use the methodplot_parameters.set()to see all possible parameters for your plot, orplot_parameters.set(keyword)to see the list of parameters including thiskeywordin itskey.This example shows how to plot a curve with a title:import numpy as np
import matplotlib.pyplot as plt
from scipy.interpolate import interp1d
import lpplotlib.pyplot as lpp

fig,ax=plt.subplots(1,1, figsize=(5,2), frameon=False)

xp=np.linspace(-20,20,40)
yp=np.random.rand(40)

x=np.linspace(-20,20,200)

f = interp1d(xp,yp, kind='quadratic')
y=f(x)

params=lpp.plot_parameters() # initialize params as an instance of class parameters
params.set('title says','Plot example') # set the plot's title

line,axis=lpp.plot(ax,x,y, pars=params)TutorialYou will find a notebook in the package distribution with the basic explanations and examples.DonationsThis is a first version of whatlpplotcan be! In the future it will be desirable to make also simpler plotting in polar corrdinates and, of course, plottnf 2d functions (contours, density, surfaces...).For this I need time, but also caffeine. Unless you are some kind of wizard, I don't see the way you can help me with time, but you can buy me a coffee if you have foundlpplotuseful for you!LicenseMIT LicenseCopyright (c) 2023 Luis PlajaPermission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.