I'm making graphs to be included in a Word document for publishing. I am teaching myself ggvis along the way since my (stupid?) assumption is that it is the best "environment" to make neat-looking graphs and otherwise worth investing in since you it provides "fashionable" interactive graphs also.
Everything is going fine (so far) except I can't make this histogram appear as years. Instead of 2000 it gives me 2,000.
require(data.table)
> head(dag)
[1] "1991-10-16" "1991-10-16" "1991-10-16" "1991-10-16" "1991-10-16" "1991-10-16"
ds %>% ggvis(~year(dag)) %>% layer_histograms(width=1, boundary=0)
I need at least 10 reputation to post images but maybe this link will work: https://i.sstatic.net/Kk8nb.jpg
You should be able to add the formatting to your axis:
%>% add_axis("x", title = "Year", format = "####")
On a more generic matter you may consider using ggplot
for traditional publication quality graphs. In effect, if your ambition is to produce interactive tools you will, most probably, end-up using Shiny for more advanced projects. For small demonstrations, you can employ manipulate.