question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Load .csv or .dat file in PyGMT

See original GitHub issue

Description of the problem

Hi, I am a new user on PyGMT, before I used GMT 5 to create some map and plotting the EQ data. But in PyGMT I had a bit issue when trying to load data (.csv or .dat) in my map.

Is there any clue how to load .csv or .dat data format in PyGMT?

Thank you

Full code that generated the error

PASTE CODE HERE

Full error message

PASTE ERROR MESSAGE HERE

System information

  • Operating system:
  • Python installation (Anaconda, system, ETS):
  • Version of GMT:
  • Version of Python:
  • Version of this package:
  • If using conda, paste the output of conda list below:
output of conda list
PASTE OUTPUT OF CONDA LIST HERE

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
zulfakrizacommented, May 13, 2020

Hi @weiji14

Thanks a lot, I will try it

Cheers Zulfakriza

0reactions
seismancommented, May 13, 2020

Closing the issue. Please post general questions on the GMT Community Forum.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to load data into pyGMT - GMT Community Forum
You can just use pandas.read_csv to load data from a CSV file. Or you can just pass in the filename to a pygmt...
Read more >
Source code for pygmt.datasets.tutorial
Functions to load sample data from the GMT tutorials. ... download="c") data = pd.read_csv(fname, header=1, sep=r"\s+") data.columns = [ "year", "month", ...
Read more >
Matplotlib Tutorial 7 - loading data from files - YouTube
Many times, people want to graph data from a file. There are many types of files, and many ways you may extract data...
Read more >
How to import a csv like dat file with a control character delimiter
Show activity on this post. I have a data file that has the DC4 control character as the delimiter. This is the code...
Read more >
how to import functions from another python file and use it Code ...
from file_name import function_name #do not include brackets or file types ... python list all csv in dir · Drop specific column in...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found