Description Usage Arguments Examples
Styling options for the various shapes. Used inside m_add_sphere()
,
m_add_arrow()
, m_add_cylinder()
etc.
1 2 3 4 5 6 7 8 9 10 11 12 |
color |
Solid color values. |
opacity |
Transparency value. 1 for opaque, 0 for invisible. |
wireframe |
Draw as wireframe, not solid surface. |
hidden |
If true, do not display object. |
frame |
If set, only display in this frame of an animation. |
clickable |
If true, user can click on object to trigger callback. |
callback |
Function to call on click. |
hoverable |
Logical, enabling hover_callback and unhover_callback functions to be called. Set hoverDuration in the viewer_spec() of r3dmol(). |
hover_callback |
Function to be called upon hover. |
unhover_callback |
Function to be called upon hover stopping. |
1 2 3 4 5 6 7 8 9 10 11 | library(r3dmol)
## Not run:
r3dmol() %>%
m_add_model(data = m_fetch_pdb("1bna")) %>%
m_add_sphere(
center = m_sel(resi = 1),
spec = m_shape_spec(color = "green", wireframe = TRUE)
) %>%
m_zoom_to(sel = m_sel(resi = 1))
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.