# Plot3d : what am I doing wrong?

**URL:** <https://forum.generic-mapping-tools.org/t/plot3d-what-am-i-doing-wrong/3352>\
**Category:** Q&A\
**Created:** [October 15, 2022, 12:35pm UTC](https://forum.generic-mapping-tools.org/t/plot3d-what-am-i-doing-wrong/3352 "2022-10-15T12:35:43Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![PlanetGus](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/planetgus/32/303_2.png) [@PlanetGus](https://forum.generic-mapping-tools.org/u/PlanetGus)\
**Post date:** [October 15, 2022, 12:35pm UTC](https://forum.generic-mapping-tools.org/t/plot3d-what-am-i-doing-wrong/3352/1 "2022-10-15T12:35:43Z")

</div>

Hi there,  
I’m trying to create a scatter plot of hypocentre underneath a volcanic structure.  
I tried to play with `plot3d` but it keeps failing.  
At first I used a `.csv` with `-i` for lon/lat/depth : nothing  
Then I used `awk` to create a text file with just lon/lat/depth : still nothing

```auto
gmtinfo [ERROR]: No data columns to work with - exiting
gmtinfo [ERROR]: Data file only has trailing text. GMT expects numerical columns followed by optional trailing text
[Session gmt (0)]: Error returned from GMT API: GMT_OBJECT_NOT_FOUND (60)

```

Finally I injected the coordinates directly in-line to no avail, only 1 point is shown.

```auto
gmt plot3d -Ra -JM10c -JZ1c -Sc0.1c -Gred -Bafg -p210/30 -png test << EOF
-60.638500 14.052167 6.36
-60.558833 15.332167 30.0
-62.130833 17.402000 46.0
-61.890667 16.472167 150.51
-61.902333 17.504500 0.0
-60.722167 15.989667 29.08
-61.173667 15.327667 140.55
-62.981667 17.400167 169.77
EOF

```

Is it some kind of bug or my data are not in the correct formatting ?

And is it possible to have small sphere (not a focal mechanism) instead of a flat circle ?

`gmt --version : 6.5.0_ffc5eba_2022.09.14`

---

<div class="post-metadata">

**Author:** ![Esteban82](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/esteban82/32/54_2.png) [@Esteban82](https://forum.generic-mapping-tools.org/u/Esteban82)\
**Post date:** [October 15, 2022, 2:18pm UTC](https://forum.generic-mapping-tools.org/t/plot3d-what-am-i-doing-wrong/3352/2 "2022-10-15T14:18:42Z")

</div>

I suspect that `-Ra` only reads the X and Y values of your data. Try this instead `-R-63/-60/14/17/0/170` .

 ![test](https://canada1.discourse-cdn.com/flex047/uploads/gmt/original/2X/0/026bf4954e18be57ec02f9adb3ee224dce6a2312.png)

---

<div class="post-metadata">

**Author:** ![PlanetGus](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/planetgus/32/303_2.png) [@PlanetGus](https://forum.generic-mapping-tools.org/u/PlanetGus)\
**Post date:** [October 15, 2022, 2:38pm UTC](https://forum.generic-mapping-tools.org/t/plot3d-what-am-i-doing-wrong/3352/3 "2022-10-15T14:38:56Z")

</div>

Alright alright … Thanks @Esteban82. I’ll open an issue or a feature request on github.

@pwessel : should I open another one for the sphere symbol too?

---

<div class="post-metadata">

**Author:** ![Joaquim](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/joaquim/32/16_2.png) [@Joaquim](https://forum.generic-mapping-tools.org/u/Joaquim)\
**Post date:** [October 15, 2022, 2:57pm UTC](https://forum.generic-mapping-tools.org/t/plot3d-what-am-i-doing-wrong/3352/4 "2022-10-15T14:57:25Z")

</div>

The (lack of) spheres is a known issue, awaiting for its time (need a PostScript solution)

---

<div class="post-metadata">

**Author:** ![PlanetGus](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/planetgus/32/303_2.png) [@PlanetGus](https://forum.generic-mapping-tools.org/u/PlanetGus)\
**Post date:** [October 16, 2022, 12:17pm UTC](https://forum.generic-mapping-tools.org/t/plot3d-what-am-i-doing-wrong/3352/5 "2022-10-16T12:17:41Z")

</div>

would a custom symbol help? Or would it be flattened too with perspective?  
Why are we able to plot “earth” as a 3D sphere and not a symbol ?

---

<div class="post-metadata">

**Author:** ![Joaquim](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/joaquim/32/16_2.png) [@Joaquim](https://forum.generic-mapping-tools.org/u/Joaquim)\
**Post date:** [October 16, 2022, 1:15pm UTC](https://forum.generic-mapping-tools.org/t/plot3d-what-am-i-doing-wrong/3352/6 "2022-10-16T13:15:35Z")

</div>

I guess yes. If the symbol is made of a grdview of a triangulated surface then yes, but it would be terribly inefficient.

We don’t have Earth as a sphere, do we?

---

<div class="post-metadata">

**Author:** ![PlanetGus](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/planetgus/32/303_2.png) [@PlanetGus](https://forum.generic-mapping-tools.org/u/PlanetGus)\
**Post date:** [October 16, 2022, 1:27pm UTC](https://forum.generic-mapping-tools.org/t/plot3d-what-am-i-doing-wrong/3352/7 "2022-10-16T13:27:48Z")

</div>

Not exactly through `-p` perspective … but… I mean … [there’s curvature!](https://docs.generic-mapping-tools.org/dev/animations/anim09.html)

---

<div class="post-metadata">

**Author:** ![Joaquim](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/joaquim/32/16_2.png) [@Joaquim](https://forum.generic-mapping-tools.org/u/Joaquim)\
**Post date:** [October 16, 2022, 10:27pm UTC](https://forum.generic-mapping-tools.org/t/plot3d-what-am-i-doing-wrong/3352/8 "2022-10-16T22:27:31Z")

</div>

The disks (circles) are curved too 🙂

---

<div class="post-metadata">

**Author:** ![PlanetGus](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/planetgus/32/303_2.png) [@PlanetGus](https://forum.generic-mapping-tools.org/u/PlanetGus)\
**Post date:** [October 17, 2022, 7:52am UTC](https://forum.generic-mapping-tools.org/t/plot3d-what-am-i-doing-wrong/3352/9 "2022-10-17T07:52:51Z")

</div>

Fair enough 😅
