Yeah, actually I verified that ggsave recorded the dpi 300 metadata. So its entirely a mac inspector phenom.
library(magick)
img <- image_read("plot.png")
image_attributes(img)
property value
1 date:create 2021-03-23T19:28:03+00:00
2 date:modify 2021-03-23T19:28:04+00:00
3 png:IHDR.bit-depth-orig 8
4 png:IHDR.bit_depth 8
5 png:IHDR.color-type-orig 3
6 png:IHDR.color_type 3 (Indexed)
7 png:IHDR.interlace_method 0 (Not interlaced)
8 png:IHDR.width,height 1500, 1500
9 png:pHYs x_res=11811, y_res=11811, units=1
10 png:PLTE.number_colors 101
11 png:sRGB intent=0 (Perceptual Intent)
References
PNG Options and Extensions (PNG: The Definitive Guide) (libpng.org)
on line 9 - png:pHYs
we see that units is 1, so its meters. The image is 11811 pixels per meter left to right
its 1500 pixels wide, so thats a phyisical distance of
> 1500 / 11811
[1] 0.1270003
0.127 meters.
which is
5Inches.