Unable to plot TrendLines

Posted by: vaidyanathan.sreeram on 13 September 2021, 7:34 pm EST

  • Posted 13 September 2021, 7:34 pm EST

    I am using the following html in Angular 2 inside wj-flex-chart tag with other properties but unable to plot any trendLine.

    <wj-flex-chart-trend-line #trendLine

    [binding]=“‘y’”

    [fitType]=“‘Linear’”

    [name]=“‘Linear’”

    [order]=“2”

    [style]=“{stroke:‘darkred’,strokeWidth:3}”

    [visibility]=“‘Visible’”>



    Using json data to plot the same.

    Wijmo Version : 5.20212.812

    Please let me know if any thing else needs to be added in the code.

  • Posted 14 September 2021, 4:45 pm EST

    Hello,

    We apologize but we are unable to replicate the issue at our end, could you please provide some more information like:

    1. JSON data structure you are using in the chart
    2. If possible, a sample replicating the issue

    Also, make sure that you are passing the correct binding to the wj-flex-chart-trend-line. We have prepared a sample to replicate your issue, please refer to the sample link below and let us know if there is anything a need to change to replicate the issue.

    https://stackblitz.com/edit/angular-s6m5sv?file=src%2Fapp%2Fapp.component.ts

    Regards

    Sonu Kumar Pandey

  • Posted 15 September 2021, 12:42 pm EST - Updated 3 October 2022, 3:30 am EST

    Thanks a lot for prompt reply.

    I tried everything, checked my template code, data format, ts file, modules, packages, even copied your example along with the data file. Checked every thing thoroughly, but still no trendline (not even console or JS errors)

    The only difference in my repo code and the example you shared, is Angular version. Please confirm if that is the case.

    I am using “@angular/core”: “5.2.6”; and the one in example is 11.2.14

  • Posted 15 September 2021, 4:36 pm EST

    Hello,

    We apologize, but still, we are unable to replicate the issue at our end. I have run the sample on the angular version “5.2.6” as you have mentioned in your response above, but still unable to replicate your issue. Please refer to the sample link below for reference:

    sample link: https://stackblitz.com/edit/angular-8op9n5?file=app%2Fapp.component.html

    Could you please provide a sample replicating the issue? so that we can properly investigate the issue to provide you better assistance.

    Regards

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels