Skip to content
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

xtick and xticklabels #88

Closed
tbeason opened this issue Jan 3, 2018 · 3 comments
Closed

xtick and xticklabels #88

tbeason opened this issue Jan 3, 2018 · 3 comments

Comments

@tbeason
Copy link

tbeason commented Jan 3, 2018

For a Linear plot, I've been trying to find a way to change the ticklabels using PGFPlots. So far, I haven't been successful. It would be cool if these options could be added in.

I see in the docs there is something about a customOptions keyword, but it doesn't look like there is any such thing implemented.

@tawheeler
Copy link
Member

How about:

Axis(Plots.Linear([1,2,3], [4,5,6]), style="xtick={1.5,2.7}, xticklabels={hi, there}")

@tawheeler tawheeler reopened this Jan 3, 2018
@tbeason
Copy link
Author

tbeason commented Jan 3, 2018

Ah ok that works. It is a bit dirty though. Would be helpful I suppose to mention in the docs. Does that trick work for all pgfplots options that aren't explicitly given PGFPlots keywords?

@tawheeler
Copy link
Member

Yes, style for Plots elements, GroupPlot, and Axis all allow you to pass in a string in the traditional tikz fashion. There is also a Plots.Command for more control over entries.

There was a push to construct a more rigid, tikz-data-structured version of PGFPlots. See #69

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants