# MROUND

## Syntax of the MROUND function

The MROUND function in DAX has the following syntax:

MROUND(❰number❱, ❰multiple❱)

``` - `❰number❱`: This is the number that you want to round to the nearest specified multiple. - `❰multiple❱`: This is the value that you want to round to. The `❰number❱` argument is rounded to the nearest multiple of this value. Examples of Using the MROUND Function in Power BI Example 1: Rounding to the nearest dollar Suppose you have a dataset that contains sales data for a particular store and you want to round the sales figures to the nearest dollar. You can achieve this by using the MROUND function as follows: ```

= MROUND(Sales[Amount], 1)

``` This formula will round the `Amount` column in the `Sales` table to the nearest dollar. Example 2: Rounding to the nearest thousand Suppose you have a dataset that contains data on employee salaries and you want to round the salaries to the nearest thousand dollars. You can achieve this by using the MROUND function as follows: ```

= MROUND(Employee[Salary], 1000)

``` This formula will round the `Salary` column in the `Employee` table to the nearest thousand dollars. Example 3: Rounding to the nearest 0.5 Suppose you have a dataset that contains data on stock prices and you want to round the stock prices to the nearest 0.5. You can achieve this by using the MROUND function as follows: ```

= MROUND(Stock[Price], 0.5)

``` This formula will round the `Price` column in the `Stock` table to the nearest 0.5. The MROUND function in DAX is a powerful tool that can be used to round a given number to the nearest specified multiple. It can be especially useful when dealing with financial data or when performing calculations that require a specific level of accuracy. In this article, we have explored how to use the MROUND function in Power BI and provided some examples to demonstrate its capabilities. With this knowledge, you can now use the MROUND function to round numbers in your own Power BI projects. Power BI DAX Training Courses by G Com Solutions (0800 998 9248) Power BI DAX Intensive Training Course £1,260.00 – £31,860.00 Select optionsContinue Loading Done Power BI DAX Introduction £474.00 – £11,700.00 Select optionsContinue Loading Done Power BI DAX Intermediate £474.00 – £11,700.00 Select optionsContinue Loading Done Power BI DAX Advanced £474.00 – £11,700.00 Select optionsContinue Loading Done Upcoming Courses 16-18 September 202411-13 November 2024 Contact Us Subject Your Name (required) Company/Organisation Email (required) Telephone Training Course(s) Power BI Intensive TrainingPower BI introduction Power BI IntermediatePower BI AdvancedDAXPower Query MPower BI CertificationPower BI AdministrationPower PlatformPower AutomatePower AppsOTHER Your Message Upload Example Document(s) (Zip multiple files) ```
``` ```
``` ```
``` ```
``` ```
``` ```