1

i have a txt data where each line is one lightning with lat, lon and intensity, i want to plot this upper a shapefile (polygon).

I cant read the shapefile, and i dont know how to plot the data upper the shapefile, anyone can help me? Maybe with some idea ..

1 Answer 1

1

Package sp is your friend here.

library(sp)

data(meuse)

str(meuse)

coordinates(meuse) <- ~ x + y
plot(meuse)

You could also could give package sf a try. See vignettes.

Sign up to request clarification or add additional context in comments.

2 Comments

i got sucessul in ploting the data ! thanks. But how can i plot this on the shape file? how i read and plot both?
@MatheusRegis have you tried searching the internet on how to read in a .shp file? For instance: gis.stackexchange.com/questions/19064/…

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.