# NOT RUN {
library(r3dmol)
model <- r3dmol() %>%
m_add_model(data = pdb_6zsl, format = "pdb") %>%
m_set_style(style = m_style_cartoon(color = "spectrum")) %>%
m_zoom_to()
# spin the model
model %>% m_spin()
# reverses the direction of spin
model %>% m_spin(speed = -0.5)
# }
Run the code above in your browser using DataLab