Thursday, June 22, 2023

Explain the Number Function ' DEGREE ' in Tableau with Example?

 In Tableau, the DEGREE function is a number function that converts an angle from radians to degrees. It allows you to convert the measurement of an angle from the radian unit to the degree unit.

The syntax for the DEGREE function in Tableau is as follows:

  • angle is the angle in radians that you want to convert to degrees.

Here's an example to illustrate the usage of the DEGREE function in Tableau:

Suppose you have a dataset with a column called "Angle" that contains different angle values in radians.


To convert the "Angle" column from radians to degrees using the DEGREE function, you can create a calculated field in Tableau:

  1. Right-click on a blank area in the "Data" pane in Tableau.
  2. Select "Create Calculated Field."
  3. In the formula editor, enter the following expression:

  1. Click "OK" to create the calculated field.

The calculated field, which utilizes the DEGREE function, will convert each value in the "Angle" column from radians to degrees.

The resulting dataset will be as follows:

AngleAngle (in degrees)

In this example, the DEGREE function converts each angle value in the "Angle" column from radians to degrees. For instance, 0.0 radians is equivalent to 0.0 degrees, 1.2 radians is approximately 68.7549 degrees, and so on.

The DEGREE function is useful when you need to work with angles in degrees instead of radians. By utilizing the DEGREE function in Tableau, you can easily convert angle measurements and perform calculations or visualizations based on degrees rather than radians.

No comments:

Post a Comment

If you have any doubts. Please let me know

How can you create an alias for a table in a SQL query?

In SQL, you can create an alias for a table in a query to give the table a temporary, alternative name that you can use in the query. Table ...