Calculate Inverse cosine of a value in R Programming – acos() Function
Last Updated :
01 Jun, 2020
acos()
function in R Language is used to calculate the inverse cosine value of the numeric value passed to it as argument.
Syntax: acos(x)
Parameter:
x: Numeric value
Example 1:
x1 < - - 1
x2 < - 0.5
acos(x1)
acos(x2)
|
Output:
[1] 3.141593
[1] 1.047198
Example 2:
x1 < - 0.224587
x2 < - 0.456732
acos(x1)
acos(x2)
|
Output:
[1] 1.344277
[1] 1.096478
Like Article
Suggest improvement
Share your thoughts in the comments
Please Login to comment...