plot - unit length arrows() R -


wondering if there way make arrows unit length in r using function arrows(). doing following:

x0<- c(results_15[(1:3479),1]) y0<- c(results_15[(3479:1),2])  x1<- (x0 + c(results_m_cos_20[,9])) y1<- (y0 - c(results_m_sin_20[,9]))  arrows(x0, y0, x1, y1, length = 0.1, angle = 25,        code = 2, col = "black", lty = 1,        lwd = 1, xpd=true) 

results_m_cos , results_m_sin give me increases in x , y respectively, make arrows maintain same direction (so same cos:sin ratio), want arrows unit length. ideas on how this? or should using totally different function and/or package plot arrows?


Comments

Popular posts from this blog

node.js - Node js - Trying to send POST request, but it is not loading javascript content -

javascript - Replicate keyboard event with html button -

javascript - Web audio api 5.1 surround example not working in firefox -