Skip to content
Related Articles

Related Articles

Compute the tangent value which is multiples of pi in R Programming – tanpi() Function
  • Last Updated : 10 Jun, 2020

tanpi() function in R Language is used to compute the tangent value of x which is the multiples of pi.

Syntax: tanpi(x)

Parameters:
x: Numeric value, array or vector

Example 1:




# R program to illustrate 
# tanpi function 
    
# Calling the tanpi() function 
tanpi(0
tanpi(1 / 4

Output:

[1] 0
[1] 1

Example 2:




# R program to illustrate 
# tanpi function 
    
# Calling the tanpi() function 
tanpi(2 / 3
tanpi(1 / 2

Output:

[1] -1.732051
[1] NaN
My Personal Notes arrow_drop_up
Recommended Articles
Page :