我有一个从互联网上传的形状.根据计算出的质心,我想从它绘制一条50度线,并找到与轮廓相交的坐标.不知道怎么办呢?
谢谢.
脚本:
library(ggplot2)
df = read.table("E:/cloud1.txt") #stored at https://ufile.io/zq679
colnames(df)<- c("x","y")
meanX <- mean(df$x)
meanY <- mean(df$y)
ggplot(df, aes(x, y))+ geom_point()+ geom_point(aes(meanX, meanY),colour="green",size=2)
Run Code Online (Sandbox Code Playgroud)