How to convert dat to gmt

27 views
Skip to first unread message

Juan Diaz-Naveas

unread,
May 23, 2021, 4:02:54 PM5/23/21
to mirone
Dear Joaquim,

I would like to use gmtedit, but because the module to convert .dat files to .gmt files is not longer available in GMT I don't know how to input my data, which consists of lon, lat, depth values.

I tried  using gmt convert on GMT6.2, but I don't know what type of fields is gmtedit expecting and Mirone sent the message:

An error occurred in the callback : mirone('GeophysicsImportGmtFile_CB',guidata(
gcbo),'single')
The error message caught was      : A memory allocation request failed.

I edit the file OPTcontrol.txt and inserted the line MIR_GMTEDIT -Vlon,lat,depth, but it doesn't work either.

Any help will be very much appreciated.

Best wishes

Juan Diaz-Naveas

Joaquim Manuel Freire Luís

unread,
May 23, 2021, 7:13:44 PM5/23/21
to mir...@googlegroups.com

Hi Juan

 

It’s been a while since I last used the old .gmt format. I have somewhere a matlab program to convert to .gmt but this format needs also date and time besides the lon, lat, GMT

I think the option you have is to use the new netCDF format provided by the mgd77 GMT supplement. gmtedit can read those nc files as well.

 

Best regards

 

Joaquim

--
You received this message because you are subscribed to the Google Groups "mirone" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mirone+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/mirone/09a91102-7cdb-47fc-ae6b-ca9eb6ee3be4n%40googlegroups.com.

Juan Diaz-Naveas

unread,
May 25, 2021, 10:18:34 AM5/25/21
to mirone
Dear Joaquim,

Thank you very much for your hints. After reading GMT's MGD77 documentation I managed to create the .nc files and to load them into Mirone's gmtedit.

However, there was something that didn't worked (although this point is not related to Mirone but to GMT). I could not produce MGD77 headers with the mgd77header comand:

# gmt mgd77header AMLR90T -HAMLR90.txt -Mf -V > AMLR90T.h77
mgd77header [INFORMATION]: Now processing cruise AMLR90T
mgd77header [ERROR]: NetCDF: Not a valid ID

Do you have any idea about what is going on here?

Best wishes

Juan Diaz-Naveas
Reply all
Reply to author
Forward
0 new messages