Skip to content

Does not work right for big number #3

Description

@TrinhNC

Hi,

I'm trying this package with linear polyfit (polyfit_boost(x, y, 1)) for the values below, but it output different values as numpy.

x = { 1644487998.203166, 1644487998.319793, 1644487998.4947336, 1644487998.669674, 1644487998.7863007, 1644487998.9612412, 1644487999.1361816, 1644487999.311122, 1644487999.544376, 1644487999.6610029, 1644487999.8359432, 1644488000.0108836, 1644488000.185824, 1644488000.4190779, 1644488000.5357049}

y = { 836.64453867, 842.21457824, 849.86294357, 858.0944194 , 863.41256084, 870.97044193, 880.09775508, 887.30253895, 
898.01580567, 903.36690136, 910.9577752 , 918.34186103, 926.03658193, 936.03563531, 940.99893027 }

testValuesX = { 1644488000.6940126 }

polyfit_boost outputs:

Coefficients:
-9.57285e+07 0.0582123
Fitted y Values:
888.236

Numpy outputs:

Coefficients:
[ 4.48627229e+01 -7.37762086e+10]
Fitted y Values:
948.9762878417969

Do you have any solutions?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions