How do I create a Cumulative Cost Curve

2 views (last 30 days)
Dora de Melo
Dora de Melo on 31 Jan 2019
I am trying to produce a cumulative cost curve as a function of volume. I have a 50x2 file opened. The first column (X) is the volume, the second column (Y) is cost. Basically, if X1=X2, then the period should be that long (2 units), and the cost should be the average of Y1 and Y2.
That is, if X(i) equals X(i+1), X(i+2), etc, then the x axis needs to be that long and the y axis needs to be the average of the costs associated with each of those volumes.
I am very stuck! Please help :)

Answers (0)

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!