-
Notifications
You must be signed in to change notification settings - Fork 643
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to show all date scales? #247
Comments
There is no direct support for that inside mpfinance, but you can get access to the Figure and Axes, which will then allow you to directly use matplotlib methods ( such as ax.xaxis.set_major_locator(matplotlib.ticker.MultipleLocator(1)) ). There are two ways to get access to the Figure and Axes as described here. Once you have access to the Axes, it may, or may not, be as simple as calling If As I mentioned, I don't know how this will interact with setting the major locator; it may be just fine with no issues at all. Please let me know how it works out, or if you have any further questions. All the best. --Daniel |
I have solved this problem by temporarily modifying the plotting.py I can change the interval by modifying the parameter value of the 'MultipleLocator' |
Thank you for providing your solution. I will take a look and perhaps provide a kwarg to integrate it as an option to mpf.plot(). |
@DanielGoldfarb I just modified that part of the code of 'plotting.py', because I passed in the two parameters 'savefig' and 'tight_layout'. if a kwarg to integrate it as an option, this will consider more modifications. |
@2628202057 |
in matplotlib,i can do like this:
ax.xaxis.set_major_locator(matplotlib.ticker.MultipleLocator(1))
The text was updated successfully, but these errors were encountered: