Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

If I understand correctly you have something like that:

import numpy as np
x = np.arange(0, 2 * np.pi, .1)
a = np.cos(x)
b = np.sin(x)

And you plot it like that:

P = list_plot(zip(x, a))
P += list_plot(zip(x, b))
P

It will lead to the plot of two sets of points with ticks .5 for y axis and 1 for the x axis. You may consider switching from list_plot to line and also specify ticks manually. Here is the set of custom parameters I typically use during plotting:

P = line(zip(x, a), linestyle='--', legend_label='$cos(x)$', thickness=4)
P += line(zip(x, b), color='black', legend_label='$sin(x)$', marker='o')
P.show(axes=False, frame=True, gridlines=True, ticks=(.5, .2), title='Plotting of $sin(x)$ and $cos(x)$')