Skip to content

Commit

Permalink
Add a new example
Browse files Browse the repository at this point in the history
  • Loading branch information
matthewturk committed Jul 6, 2024
1 parent 7f38dc9 commit cdb15c4
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions examples/histogram_ex.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import yt

import yt_idv
from yt_idv.scene_annotations.block_histogram import BlockHistogram

ds = yt.load_sample("IsolatedGalaxy")

rc = yt_idv.render_context(height=800, width=800, gui=True)
sg = rc.add_scene(ds, "density", no_ghost=True)
bh = BlockHistogram(data=sg.data_objects[0], bins=64)
sg.annotations = sg.annotations + [bh]
# rc.run()

0 comments on commit cdb15c4

Please sign in to comment.