# Values of a GMT colormap

**URL:** <https://forum.generic-mapping-tools.org/t/values-of-a-gmt-colormap/2241>\
**Category:** Q&A\
**Tags:** gmt\
**Created:** [October 31, 2021, 12:51pm UTC](https://forum.generic-mapping-tools.org/t/values-of-a-gmt-colormap/2241 "2021-10-31T12:51:13Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![leon6j](https://avatars.discourse-cdn.com/v4/letter/l/a6a055/32.png) [@leon6j](https://forum.generic-mapping-tools.org/u/leon6j)\
**Post date:** [October 31, 2021, 12:51pm UTC](https://forum.generic-mapping-tools.org/t/values-of-a-gmt-colormap/2241/1 "2021-10-31T12:51:13Z")

</div>

In Matlab, I understand their colormap is a n by 3 array, something like the below:  
0.2, 0.3, 0.2  
0.5, 0.5, 0.7  
…

I wonder is there a way I can get the numerical values of the colormaps in GMT? Specifically, I need to do this for the colormap “geo”.

Many thanks!

---

<div class="post-metadata">

**Author:** ![pwessel](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/pwessel/32/30_2.png) [@pwessel](https://forum.generic-mapping-tools.org/u/pwessel)\
**Post date:** [October 31, 2021, 9:36pm UTC](https://forum.generic-mapping-tools.org/t/values-of-a-gmt-colormap/2241/2 "2021-10-31T21:36:35Z")

</div>

A quick check of the makecpt documentation suggest perhaps

`gmt makecpt -Cgeo -Fr`

You will have to convert this to a single 3-column table though.

---

<div class="post-metadata">

**Author:** ![leon6j](https://avatars.discourse-cdn.com/v4/letter/l/a6a055/32.png) [@leon6j](https://forum.generic-mapping-tools.org/u/leon6j)\
**Post date:** [October 31, 2021, 11:29pm UTC](https://forum.generic-mapping-tools.org/t/values-of-a-gmt-colormap/2241/3 "2021-10-31T23:29:10Z")

</div>

Many thanks! 👍
