# Scatterplot linewidth does not disappear when render to pdf

**URL:** <https://discourse.julialang.org/t/scatterplot-linewidth-does-not-disappear-when-render-to-pdf/61556>\
**Category:** General Usage\
**Tags:** plotting\
**Created:** [May 21, 2021, 4:59am UTC](https://discourse.julialang.org/t/scatterplot-linewidth-does-not-disappear-when-render-to-pdf/61556 "2021-05-21T04:59:17Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![andresmz](https://avatars.discourse-cdn.com/v4/letter/a/ea666f/32.png) [@andresmz](https://discourse.julialang.org/u/andresmz)\
**Post date:** [May 21, 2021, 4:59am UTC](https://discourse.julialang.org/t/scatterplot-linewidth-does-not-disappear-when-render-to-pdf/61556/1 "2021-05-21T04:59:17Z")

</div>

Hello. I’ve been trying to plot this database and save it on pdf. I’m not really sure why it it still shows the linewidth if I set it 0. This does not happen when I save it as a png file.  
Here is the code I am using:

```julia
gr()
q = plot(size=(1000,1000), camera = (70,30),dpi=300)
colors = ["#FFC857","#26c485","#B84A62","#854d27","#F15025","#30292f","#6457A6"]
for c in 1:k
    lab = [i for i in 1:size(datos_semi)[1] if kmeans_res.assignments[i]==c]
    scatter!(datos_semi[lab,2],datos_semi[lab,3],datos_semi[lab,4],markersize=2,alpha=1,color=colors[c],edgecolor=false, markerstrokewidth = false, linewidth=false )
end
savefig("prueba.pdf")
savefig("prueba.png")
q

```

This is a screenshot of the pdf (sadly as a new user I can’t add a second media item to show the png).

- ![Screenshot 2021-05-20 at 23.55.57](https://global.discourse-cdn.com/julialang/original/3X/1/7/17ae1dadea3a4c9befaad3f54457e76048c9f317.png)

Hope I can get some help! 🙃

---

<div class="post-metadata">

**Author:** ![rafael.guerra](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rafael.guerra/32/216610_2.png) [@rafael.guerra](https://discourse.julialang.org/u/rafael.guerra)\
**Post date:** [May 21, 2021, 7:58am UTC](https://discourse.julialang.org/t/scatterplot-linewidth-does-not-disappear-when-render-to-pdf/61556/2 "2021-05-21T07:58:39Z")

</div>

Why not reducing marker size one notch and setting identical `markerstrokecolor`?

Resulting PDF looks great:

```julia
using Plots; gr()

plot(size=(1000,1000), dpi=300)
scatter(rand(20),rand(20), ms=5, mc=:red, msc =:red)
scatter!(rand(20),rand(20), ms=5, mc=:green, msc =:green)
savefig("PDF_markerstrokecolor.pdf")

```

 ![PDF_markerstrokecolor](https://global.discourse-cdn.com/julialang/original/3X/d/e/dede19940e714e7580d8479aa928ab78b7537950.png)
