hrbrmstr / metricsgraphics

:chart_with_upwards_trend: htmlwidget interface to the MetricsGraphics.js D3 chart library
http://hrbrmstr.github.io/metricsgraphics/
Other
132 stars 35 forks source link

mjs_add_marker not working with mjs_histogram #48

Open buggythepirate opened 8 years ago

buggythepirate commented 8 years ago

Hi there,

It seems that mjs_add_marker is not working in conjunction with mjs_histogram.

mjs_plot(full_summary[(var_id=="Tot"),.(sum_val)], x=sum_val, decimals = 0, width=300, height=300) %>% mjs_histogram(bar_margin=2) %>% mjs_add_marker(x_value=average_val, label="Av. Val") %>% mjs_labs(x_label="Total value")

It will plot the histogram, but the vertical marker is not plotted.

Version: metricsgraphics 0.9.0 R-Version: 3.2.3