Skip to main content
Announcements
July 15, NEW Customer Portal: Initial launch will improve how you submit Support Cases. IMPORTANT DETAILS
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Diffrentiation

Hi All,

Following is a requirement that has been taunting me for a week now.

I have a period wise sales info upto current month. I have plotted this in a line chart, with Period as dimension and Sum(Sales) as Expression.

Now my client wants me to extend and project the sales, but he doesnt want it to be done using linest_m and linest_b.

Rather he wants it to done as follows.

1. Till current month the line should plot the actuall data.

2. After that it should continue the flow and go as a straight line (which is not the linear line). Actually what he asks for is to find the slope of the line curve at the current month and continue by drawing a line from there.

Hope I have explained enough.

Any help is appreciated.

Thanks in advance.

Br,

Prasanna.

1 Solution

Accepted Solutions
swuehl
MVP
MVP

Well, it seems to me that the client has already made the decision (continue forecast with the slope taken from the last two data points).

I've attached a sample of how you could do this, using the script, or using only expressions in the frontend.

I also switch to forecast in one expression or display the data using two expressions, choose what you like better.

In general, you need to take care of how your data is structured in your table, i.e. if the sampling points are equidistant (one data point per month), appropriately ordered by period (this was the case in your sample), and how to handle the year changes (I introduced a periodID in the script and used date conversions and calculations in the frontend).

Hope this helps,

Stefan

View solution in original post

5 Replies
perumal_41
Partner - Specialist II
Partner - Specialist II

Hi

If Possible Upload ur Sample File

Regards

Perumal A

Not applicable
Author

Hi Perumal,

Thanks for asking....

I have attached a sample file indicating what i have done now and what i actually want in an image....

Kindly look and get back...

Br,

Prasanna

jvitantonio
Luminary Alumni
Luminary Alumni

Prasanna, let's see.

What you are asking is a forcast of your sales. This cannot be gussed. Your client needs to decide how to calculate this and then we can help you impement it. you cannot calculate a slope on a point (last month with data)

swuehl
MVP
MVP

Well, it seems to me that the client has already made the decision (continue forecast with the slope taken from the last two data points).

I've attached a sample of how you could do this, using the script, or using only expressions in the frontend.

I also switch to forecast in one expression or display the data using two expressions, choose what you like better.

In general, you need to take care of how your data is structured in your table, i.e. if the sampling points are equidistant (one data point per month), appropriately ordered by period (this was the case in your sample), and how to handle the year changes (I introduced a periodID in the script and used date conversions and calculations in the frontend).

Hope this helps,

Stefan

Not applicable
Author

Hi Stefan,

Thank you very much for ur help....

This is exactly that I was luking for....

I prefer the frontend approach....