layout(
  plot_ly(diamonds, x = ~cut),
  title = "My beatiful histogram"
)
## No trace type specified:
##   Based on info supplied, a 'histogram' trace seems appropriate.
##   Read more about this trace type -> https://plotly.com/r/reference/#histogram
diamonds %>%
  plot_ly(x = ~cut) %>%
  layout(title = "My beatiful histogram")
## No trace type specified:
##   Based on info supplied, a 'histogram' trace seems appropriate.
##   Read more about this trace type -> https://plotly.com/r/reference/#histogram
diamonds %>%
  plot_ly() %>% 
  add_histogram(x = ~cut)