• Quick visualisation of the data:

    closest_table<-plan2[,3:5]==apply(plan2[,3:5],1,min)
    cols<-rep("black",nrow(plan2))
    cols[closest_table[,2]]<-"red"
    cols[closest_table[,3]]<-"green"
    matplot(plan2[,3:10],pch=20,cex=0.4)
    points(1:nrow(plan2),rep(0,nrow(plan2)),col=cols,pch="|",cex=0.5)

    closest_planet_vis

    Edited by Christopher Porter
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment