# Build-in markers for 3D scatter

**URL:** <https://discourse.julialang.org/t/build-in-markers-for-3d-scatter/67358>\
**Category:** Visualization\
**Tags:** makie\
**Created:** [August 30, 2021, 2:38pm UTC](https://discourse.julialang.org/t/build-in-markers-for-3d-scatter/67358 "2021-08-30T14:38:37Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![phlavenk](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/phlavenk/32/1873_2.png) [@phlavenk](https://discourse.julialang.org/u/phlavenk)\
**Post date:** [August 30, 2021, 2:38pm UTC](https://discourse.julialang.org/t/build-in-markers-for-3d-scatter/67358/1 "2021-08-30T14:38:37Z")

</div>

Hi, In a 3D plot I’m trying to combine a semi-transparent mesh (detector body) with a scatter plot of particle hits in its surface (might not lie exactly on the surface, sometimes above or below, depending on the trajectory simulation step). So far, I can only see the scatter points if they are not obscured by the mesh body. And, I have to use a really big marker size to see them.

I think I’m not using the correct marker for a 3D plot, maybe small spheres would be more compatible. Are there any build-in markers or does one have to create his own? And how to cope with the transparency?

 ![image](https://global.discourse-cdn.com/julialang/original/3X/a/2/a2a4b61b780e3b4858e350e07da4393513d462fe.jpeg)  
 ![image](https://global.discourse-cdn.com/julialang/original/3X/6/d/6db266c101081f6675534ab8adb973a3f5bb1cc7.jpeg)

```julia
body_color = RGBA(colorant"deepskyblue2", 0.5)
fig = mesh(nodes, faces, color = body_color)
scatter!(x,y,z, markersize = 500)

```

---

<div class="post-metadata">

**Author:** ![lazarusA](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/lazarusa/32/6571_2.png) [@lazarusA](https://discourse.julialang.org/u/lazarusA)\
**Post date:** [August 30, 2021, 2:55pm UTC](https://discourse.julialang.org/t/build-in-markers-for-3d-scatter/67358/2 "2021-08-30T14:55:14Z")

</div>

you need to use `meshscatter`.

---

<div class="post-metadata">

**Author:** ![phlavenk](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/phlavenk/32/1873_2.png) [@phlavenk](https://discourse.julialang.org/u/phlavenk)\
**Post date:** [August 31, 2021, 6:00am UTC](https://discourse.julialang.org/t/build-in-markers-for-3d-scatter/67358/3 "2021-08-31T06:00:52Z")

</div>

Lazarus is right, moreover, one has to draw the mesh with `transparency=true`, after using this switch the opacity/visibility works as expected

```julia
body_color = RGBA(colorant"deepskyblue2", 0.5)
fig = mesh(nodes, faces, color = body_color, transparency=true)
meshscatter!(x,y,z, markersize = 0.1)

```

![image](https://global.discourse-cdn.com/julialang/original/3X/6/b/6b0271ba3479e1ba6e1c6e512e851a6be63c8e00.png)
