Hi Nathan,Since you merged the pull request to the yt codebase, I just downloaded that and tried your annotate particle method.Strangely, the annotated particles didn't show up. Not sure if this is a related issue, but if I try to draw a circle around the center with annotate_sphere, nothing shows up as well. I show a simple example below, using the EAGLE dataset from the YT data hub.eagle_fname = './data/snapshot_028_z000p000/snap_028_z000p000.0.hdf5' unit_base = {'UnitLength_in_cm' : 3.085678e+24,'UnitMass_in_g' : 1.989e+43,'UnitVelocity_in_cm_per_s' : 100000.0}ds = yt.load(eagle_fname,unit_base=unit_base) center = ds.arr(np.array([12.08809,4.474372,1.4133347]),'Mpccm') plot_cubeside = ds.quan(50,'kpc')# a cube of +/- 25 kpc from the center (50 kpc in length)boxreg_leftcorner = center - plot_cubeside/2.boxreg_rightcorner = center + plot_cubeside/2.boxreg = ds.region(center,left_edge=boxreg_leftcorner,right_edge= boxreg_rightcorner) ppx = yt.ParticleProjectionPlot(ds, 'x', fields=('PartType0','Mass'),\center=center,width=plot_cubeside,data_source=boxreg) ppx.annotate_particles(plot_cubeside, p_size=100, ptype='PartType0') ppx.annotate_sphere(center, radius=(10, 'kpc'), coord_system='data', circle_args={'color':'black'})ppx.save('test_annotateparticle.png') I wonder would this be related to some subtleties in coordinate systems that I am not aware of. I tried to specify the center in 'code_length' in annotate_sphere, but then nothing happens as well.Please let me know if there's something I have obviously missed.Thanks for you help again!StephanieOn Tue, Apr 24, 2018 at 1:11 PM, Nathan Goldbaum <nathan12343@gmail.com> wrote:Ah, that's why I didn't understand. There is no marker. You can think of the ParticleProjectionPlot as a way to visualize a 2D histogram. Rather than drawing a shape where a particle is, it identifies the pixel in an image where the particles projected position overlaps and colors in that pixel.There are two ways to make the marker generated by an individual particle bigger.One would be to make the resolution of the image lower:(the "marker" is square because it's just filling in a pixel)Another would be to draw markers using a plot annotation, in particular the particle callback. Unfortunately doing that right now requires a change to the yt codebase, which I've proposed as a pull request here:See the notebook I link to in the pull request description for a usage example.On Tue, Apr 24, 2018 at 2:49 PM, Stephanie Ho <stephaniehkho@gmail.com> wrote:Hi Nathan,With particle projection plots, each particle is represented by a dot on the plot. Is there a way to increase that size of those dots?(When there are not a lot of particles, the original dot size make it hard to see the distribution of these particles.)Thanks,StephanieOn Tue, Apr 24, 2018 at 12:45 PM, Nathan Goldbaum <nathan12343@gmail.com> wrote:Sorry, can you clarify what you are trying to customize? What marker?On Tue, Apr 24, 2018 at 2:43 PM, Stephanie Ho <stephaniehkho@gmail.com> wrote:Hi,
For particle projection plots, is there a way to increase the marker size? I am sorry if I overlooked, but I don't seem to see a relevant keyword for marker size under ParticleProjectionPlot (documentation: http://yt-project.org/doc/reference/api/yt.visualization.par )ticle_plots.html#yt.visualizat ion.particle_plots.ParticlePro jectionPlot
Thanks,
Stephanie
_______________________________________________
yt-users mailing list -- yt-users@python.org
To unsubscribe send an email to yt-users-leave@python.org
_______________________________________________
yt-users mailing list -- yt-users@python.org
To unsubscribe send an email to yt-users-leave@python.org
_______________________________________________
yt-users mailing list -- yt-users@python.org
To unsubscribe send an email to yt-users-leave@python.org
_______________________________________________
yt-users mailing list -- yt-users@python.org
To unsubscribe send an email to yt-users-leave@python.org
_______________________________________________
yt-users mailing list -- yt-users@python.org
To unsubscribe send an email to yt-users-leave@python.org