Created a Power BI report that leverages parameters, measures, and the matrix visual to allows users to input dynamic values to accurately forecast travel cost based on past travel volume and variable gas price and average fleet MPG.
Total Fuel Cost =
SUMX(
'TripTbl',
('TripTbl'[Total Miles] / [Avg Fleet MPG Value]) * [Gas Price Per Gallon Value]
)The Avg. Fleet MPG Parameter is a numeric range between 12 and 80 that increments by .1. The default value is set to 22 (MPG).
The Gas Price Per Gallon Parameter is also a numeric range with a minimum price of $1.50 and a maximum price of $8.00. The range increments by once cent with a default price of $2.15.