swsoyee / r3dmol

🧬 An R package for visualizing molecular data in 3D
https://swsoyee.github.io/r3dmol/
Other
88 stars 4 forks source link

feat(gridView): implement feature (#24) #25

Closed swsoyee closed 3 years ago

swsoyee commented 3 years ago

A dirty solution, but it works.

library(r3dmol)

m1 <- r3dmol() %>%
  m_add_model(data = pdb_6zsl, format = "pdb") %>%
  m_zoom_to()

m2 <- m1 %>%
  m_set_style(style = m_style_cartoon(color = "spectrum"))

m3 <- m1 %>%
  m_set_style(style = m_style_stick())

m4 <- m1 %>%
  m_set_style(style = m_style_sphere())

m_grid(
  viewer = list(m1, m2, m3, m4),
  configs = list(rows = 2, cols = 2, control_all = TRUE),
  viewer_config = list(backgroundColor = "black")
)
截屏2021-03-07 23 47 09
swsoyee commented 3 years ago

As I mention in 0a4e61c, some packages (dependencies) version are not available now, so the check will failed for several days. If checking locally, everything should be fine.

swsoyee commented 3 years ago

Looks good, wait for the checks to be completed and then merge it to master.

BradyAJohnston commented 3 years ago

Looks good! Merged 🎉🎉