'PowerBI: Calculating Margin net of Labour

I am new to Powerbi and needed some help on creating a dax calculation.

Objective: calculate the margin net of labour costs.

I already have a table that contains the margin$(price - cost).

Regarding labour info: the fixed wage rate is $17.00 During the week the number of hours worked is 9/ per weekday on saturday the number of hours worked is 8 on sunday the number of hours worked is 6

I want to create a function that tells me the labour cost for a given day and overall labour cost should sum as each day passes.

I figured I should create specific variables in DAX but following that is were I am confused. How do I dictate to powerbi the hours and rate to apply? any guidance?

|rate:17.00| |weekdayhours: 9| |sathours: 8| |sunhours: 6|



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source