-
Notifications
You must be signed in to change notification settings - Fork 32
How to add vertical and horizontal lines to figures? #21
Comments
In master, you can do this by layering, but that's not very convenient at the moment. It would be something like: ax = data.vgplot(x='x', y='y')
# draw a line at y = 5
hline = pd.DataFrame({'x': data.x,
'y': 5 * np.ones_like(data.x)})
hline.vgplot(x='x', y='y', ax=ax) (Note that this is not yet available in the version that's installable from pip.) I've been thinking about this use case, and whether it would make sense to add |
@jakevdp thanks. I think it would be helpful to add the |
@jakevdp I'm loving altair so far but I agree that adding I tried following the advice given on altair's issue #1124 but it didn't really work that well. Keep up the good work and thank you for this awesome library. |
Are you working in altair or in pdvega? |
In Altair, just noticed that I posted on the pdvega repo, sorry about that. I was looking everywhere for ways to draw the vertical line and didn’t realize. I can post this to Altair if you prefer. |
Maybe you could comment on vega/altair#1124 with the problem you're having with the solution there. |
Please advise.
The text was updated successfully, but these errors were encountered: