rad2deg | R Documentation |
Returns a vector after converting radians to degrees.
When overlap is set to TRUE, output is contained within the [-180, 180] set.
rad2deg(rad, overlap = T)
rad2deg(rad)
rad |
Numeric vector containing the angle values in radians. |
overlap |
A binary bit, set to FALSE by default. |
Input argument "rad" must be a numeric vector.
Input argument "overlap" must be a vector of dimension equal to unity.
Input argument "overlap" must be of logical type.
The returned value is always a vector of the same length as the argument "rad"
Chitran Ghosal
#test code for positive
test_pos <- NULL
for (i in 1:12) {
test_pos <- c(test_pos, i*pi/3)
}
v_pos <- rad2deg(test_pos, overlap = T)
test_pos
v_pos
#test code for negative
test_neg <- NULL
for (i in 1:12) {
test_neg <- c(test_neg, -i*pi/3)
}
v_neg <- rad2deg(test_neg, overlap = T)
test_neg
v_neg
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.